move src2 -> src, web2 -> web, remove old module system, fix deps
This commit is contained in:
parent
1d821d4e24
commit
ce4f5d6e78
488 changed files with 26179 additions and 26609 deletions
|
|
@ -1,20 +1,12 @@
|
|||
/** Copyright Stewart Allen <sa@grid.space> -- All Rights Reserved */
|
||||
|
||||
"use strict";
|
||||
|
||||
// dep: moto.broker
|
||||
// dep: kiri.api
|
||||
// dep: kiri.utils
|
||||
gapp.register("kiri.stats", [], (root, exports) => {
|
||||
|
||||
const { data, kiri, gapp } = root;
|
||||
const { broker } = gapp;
|
||||
const { api, utils } = kiri;
|
||||
const { js2o, o2js } = utils;
|
||||
import { local } from '../data/local.js';
|
||||
import { broker } from '../moto/broker.js';
|
||||
import { js2o, o2js } from './utils.js';
|
||||
|
||||
class Stats {
|
||||
constructor(db) {
|
||||
this.db = db || data.local;
|
||||
this.db = db || local;
|
||||
this.obj = js2o(this.db['stats'] || '{}');
|
||||
let o = this.obj, k;
|
||||
for (k in o) {
|
||||
|
|
@ -56,6 +48,6 @@ class Stats {
|
|||
}
|
||||
}
|
||||
|
||||
kiri.stats = new Stats();
|
||||
export const stats = new Stats();
|
||||
|
||||
});
|
||||
export { stats as Stats };
|
||||
|
|
|
|||
Loading…
Reference in a new issue