Skip to content

Commit

Permalink
chore: convert endpoint from module to function
Browse files Browse the repository at this point in the history
  • Loading branch information
trivikr committed Nov 10, 2021
1 parent 5a58fb9 commit 8766ac5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
6 changes: 0 additions & 6 deletions lib/metadata_service/endpoint.js

This file was deleted.

8 changes: 8 additions & 0 deletions lib/metadata_service/get_endpoint.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
var getEndpoint = function() {
return {
IPv4: 'http://169.254.169.254',
IPv6: 'http://[fd00:ec2::254]',
};
};

module.exports = getEndpoint;
2 changes: 1 addition & 1 deletion lib/metadata_service/get_metadata_service_endpoint.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
var AWS = require('../core');

var Endpoint = require('./endpoint');
var Endpoint = require('./get_endpoint')();
var EndpointMode = require('./endpoint_mode');

var ENDPOINT_CONFIG_OPTIONS = require('./endpoint_config_options').ENDPOINT_CONFIG_OPTIONS;
Expand Down

0 comments on commit 8766ac5

Please sign in to comment.