File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818- added: quicksort algorithm for sorting arrays
1919- added: `Array.quicksort(property_name, [asc])` for sorting arrays
2020- added: `String.removeTags()` by @harry-stot
21+ - added: F.nosql(name) + NOSQL(name) --> alias for NoSQL embedded database (it can be used with e.g. SQL Agent)
2122
2223- updated: `F.route(url, ...)` - `url`can be String Array with multiple relative paths by @Harry-Stot
2324- updated: `F.file()` supports flags instead of middleware and the flags supports extensions `['.jpg', '.png']`. The `name` argument has been removed.
Original file line number Diff line number Diff line change @@ -215,6 +215,10 @@ global.MODULE = function(name) {
215215 return framework . module ( name ) ;
216216} ;
217217
218+ global . NOSQL = function ( name ) {
219+ return framework . nosql ( name ) ;
220+ } ;
221+
218222global . DB = global . DATABASE = function ( ) {
219223 if ( typeof ( framework . database ) === 'object' )
220224 return framework . database ;
@@ -786,9 +790,18 @@ Framework.prototype._routesSort = function() {
786790/**
787791 * Get a database instance
788792 * @param {String } name Database name (optional)
789- * @return {Framework }
793+ * @return {Database }
790794 */
791795Framework . prototype . database = function ( name ) {
796+ return this . nosql ( name ) ;
797+ } ;
798+
799+ /**
800+ * Get a database instance (NoSQL embedded)
801+ * @param {String } name Database name (optional)
802+ * @return {Database }
803+ */
804+ Framework . prototype . nosql = function ( name ) {
792805 var self = this ;
793806 var db = self . databases [ name ] ;
794807 if ( db !== undefined )
You can’t perform that action at this time.
0 commit comments