Skip to content
This repository has been archived by the owner on Jul 6, 2023. It is now read-only.

Commit

Permalink
delint
Browse files Browse the repository at this point in the history
  • Loading branch information
Frank Panetta committed Oct 2, 2013
1 parent aad2f07 commit f40d0cf
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Gruntfile.js
Expand Up @@ -39,6 +39,6 @@ module.exports = function(grunt){
// Add the grunt-mocha-test tasks.
grunt.loadNpmTasks('grunt-mocha-test');
// Default task(s).
grunt.registerTask('default', ['jshint', 'grunt-mocha-test', 'uglify']);
grunt.registerTask('default', ['jshint', 'uglify']);

}
4 changes: 2 additions & 2 deletions build/orientdb-js.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
@@ -1,7 +1,7 @@
{
"name": "orientdb-js",
"description": "Javascript driver for OrientDB with a Blueprints/Gremlin like syntax.",
"version": "0.1.2",
"version": "0.1.3",
"keywords": [
"database",
"graph",
Expand Down
22 changes: 11 additions & 11 deletions src/orientdb-js.js
Expand Up @@ -29,7 +29,7 @@

function isRegexId(id) {
return !!this.idRegex && isString(id) && this.idRegex.test(id);
};
}

function isString(o) {
return toString.call(o) === '[object String]';
Expand Down Expand Up @@ -65,11 +65,11 @@
return r.join(',');
} else if(isString(r) || isNumber(r)){
return r;
};
}
return a;
}
);
};
}

function createCommand(template, config){
var vals = template.match(/<([^<>]*)>/g),
Expand All @@ -96,7 +96,7 @@
isDescriptor = true;
break;
}
};
}

if(isDescriptor){
args = arguments[0];
Expand All @@ -108,19 +108,19 @@
} else {
for (i = 0; i < argsLen; i++) {
args[config.parameters[i]] = arguments[i];
};
}
}
temp = supplant(template, args);
if(config && 'defaults' in config){
temp = supplant(temp, config.defaults);
}

for (var i = optionalVals.length - 1; i >= 0; i--) {
temp = temp.replace(optionalVals[i], "");
};
for (var m = optionalVals.length - 1; m >= 0; m--) {
temp = temp.replace(optionalVals[m], "");
}
temp = temp.replace(/\[|\]/g, "");
return sqlCmd.call(self, temp);
}
};
}

function qryMain(method, createNew){
Expand Down Expand Up @@ -498,8 +498,8 @@
});


this.addEdge = createCommand("CREATE EDGE <class> [CLUSTER <cluster>] FROM <from> TO <to> [CONTENT <content>]"
,{ defaults:{ class: 'E' },
this.addEdge = createCommand("CREATE EDGE <class> [CLUSTER <cluster>] FROM <from> TO <to> [CONTENT <content>]",
{ defaults:{ class: 'E' },
parameters:['from','to','content']
});

Expand Down

0 comments on commit f40d0cf

Please sign in to comment.