chore(server): Move api-server in to it's own DIR
This commit is contained in:
committed by
mrugesh mohapatra
parent
9fba6bce4c
commit
46a217d0a5
15
api-server/common/models/popularity.js
Normal file
15
api-server/common/models/popularity.js
Normal file
@ -0,0 +1,15 @@
|
||||
import { Observable } from 'rx';
|
||||
|
||||
module.exports = function(Popularity) {
|
||||
Popularity.on('dataSourceAttached', () => {
|
||||
Popularity.findOne$ = Observable.fromNodeCallback(
|
||||
Popularity.findOne,
|
||||
Popularity
|
||||
);
|
||||
Popularity.findById$ = Observable.fromNodeCallback(
|
||||
Popularity.findById,
|
||||
Popularity
|
||||
);
|
||||
Popularity.find$ = Observable.fromNodeCallback(Popularity.find, Popularity);
|
||||
});
|
||||
};
|
Reference in New Issue
Block a user