Skip to content

Commit deb6cdc

Browse files
committed
Remove x-api-id stuff
1 parent fffc107 commit deb6cdc

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

api.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ exports.api = function(args, opts) {
4242
return;
4343
}
4444

45+
/*
4546
var apiId = crypto.randomBytes(7).toString('hex');
4647
4748
if(!swagger['x-api-id']) {
@@ -74,6 +75,7 @@ exports.api = function(args, opts) {
7475
7576
}
7677
}
78+
*/
7779

7880
utils.removeMetadata(swagger);
7981

lib/init.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ exports.run = function(config, info) {
103103
inquirer.prompt(questions).then(function (answers) {
104104
var swagger = {
105105
'swagger': '2.0',
106-
'x-api-id': crypto.randomBytes(7).toString('hex'),
106+
//'x-api-id': crypto.randomBytes(7).toString('hex'),
107107
'info': {
108108
'version': answers['info.version'],
109109
'title': answers['info.title'],

utils.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ exports.getAliasFile = function(unknownAction) {
7878
};
7979

8080
exports.removeMetadata = function(obj) {
81+
// x-si = swagger inline metadata
8182
for(prop in obj) {
8283
if (prop.substr(0, 5) === 'x-si-')
8384
delete obj[prop];

0 commit comments

Comments
 (0)