total5 0.0.13-3 → 0.0.13-4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/builders.js +1 -0
- package/components.js +2 -4
- package/debug.js +4 -4
- package/flow-flowstream.js +4 -4
- package/mail.js +2 -2
- package/package.json +1 -1
- package/pypeline.js +1 -23
- package/tangular.js +6 -6
- package/viewengine.js +1 -2
package/builders.js
CHANGED
package/components.js
CHANGED
|
@@ -260,7 +260,7 @@ Instance.prototype.debug = function(msg) {
|
|
|
260
260
|
};
|
|
261
261
|
|
|
262
262
|
Instance.prototype.throw = function(err) {
|
|
263
|
-
this.module.throw(this,
|
|
263
|
+
this.module.throw(this, err);
|
|
264
264
|
};
|
|
265
265
|
|
|
266
266
|
Instance.prototype.dashboard = function(msg) {
|
|
@@ -344,8 +344,6 @@ exports.compile = function(html, callback) {
|
|
|
344
344
|
return;
|
|
345
345
|
}
|
|
346
346
|
|
|
347
|
-
var errors = [];
|
|
348
|
-
|
|
349
347
|
(com.npm || EMPTYARRAY).wait(function(name, next) {
|
|
350
348
|
NPMINSTALL(name, function(err) {
|
|
351
349
|
if (err) {
|
|
@@ -378,4 +376,4 @@ exports.compile = function(html, callback) {
|
|
|
378
376
|
callback(null, com);
|
|
379
377
|
});
|
|
380
378
|
|
|
381
|
-
};
|
|
379
|
+
};
|
package/debug.js
CHANGED
|
@@ -72,11 +72,11 @@ function runwatching() {
|
|
|
72
72
|
|
|
73
73
|
const FILENAME = F.TUtils.getName(process.argv[1] || 'index.js');
|
|
74
74
|
const VERSION = F.version_header;
|
|
75
|
-
const REG_FILES = /(config|bundles\.debug|\.js|\.ts|\.flow|\.resource)+$/i;
|
|
75
|
+
const REG_FILES = /(config|bundles\.debug|\.js|\.ts|\.flow|\.py|\.resource)+$/i;
|
|
76
76
|
const REG_PUBLIC = /\/public\//i;
|
|
77
77
|
const REG_INDEX = new RegExp(FILENAME.replace(/\.js$/, '') + '_.*?\\.js$');
|
|
78
|
-
const REG_EXTENSION = /\.(js|ts|resource|package|bundle|build|flow|url)$/i;
|
|
79
|
-
const REG_RELOAD = /\.(js|ts|css|html|htm|jpg|png|gif|ico|svg|webp|resource)$/i;
|
|
78
|
+
const REG_EXTENSION = /\.(js|ts|py|resource|package|bundle|build|flow|url)$/i;
|
|
79
|
+
const REG_RELOAD = /\.(js|ts|py|css|html|htm|jpg|png|gif|ico|svg|webp|resource)$/i;
|
|
80
80
|
const isRELOAD = !!options.livereload;
|
|
81
81
|
const SPEED = isRELOAD ? 1000 : 1500;
|
|
82
82
|
const ARGV = F.TUtils.clone(process.argv);
|
|
@@ -551,4 +551,4 @@ function init() {
|
|
|
551
551
|
setImmediate(runapp);
|
|
552
552
|
}
|
|
553
553
|
|
|
554
|
-
Meta.delay = setTimeout(init, 100);
|
|
554
|
+
Meta.delay = setTimeout(init, 100);
|
package/flow-flowstream.js
CHANGED
|
@@ -1019,9 +1019,9 @@ function init_current(meta, callback, nested) {
|
|
|
1019
1019
|
flow.proxy.ping = 0;
|
|
1020
1020
|
|
|
1021
1021
|
if (meta.import) {
|
|
1022
|
-
|
|
1023
|
-
for (
|
|
1024
|
-
|
|
1022
|
+
let tmp = meta.import.split(/,|;/).trim();
|
|
1023
|
+
for (let m of tmp) {
|
|
1024
|
+
let mod = require(F.path.root(m));
|
|
1025
1025
|
mod.install && mod.install(flow);
|
|
1026
1026
|
mod.init && mod.init(flow);
|
|
1027
1027
|
}
|
|
@@ -3382,4 +3382,4 @@ if (process.argv[1].endsWith('flow-flowstream.js')) {
|
|
|
3382
3382
|
});
|
|
3383
3383
|
}
|
|
3384
3384
|
|
|
3385
|
-
}
|
|
3385
|
+
}
|
package/mail.js
CHANGED
|
@@ -731,7 +731,7 @@ Mailer.$send = function(obj, options, autosend) {
|
|
|
731
731
|
isAuthorization = true;
|
|
732
732
|
if (options.token && line.indexOf('XOAUTH2') !== -1) {
|
|
733
733
|
auth.push('AUTH XOAUTH2');
|
|
734
|
-
auth.push(Buffer.from('user=' + options.user + '\
|
|
734
|
+
auth.push(Buffer.from('user=' + options.user + '\x01auth=Bearer ' + options.token + '\x01\x01').toString('base64'));
|
|
735
735
|
} else if (line.lastIndexOf('XOAUTH') === -1) {
|
|
736
736
|
auth.push('AUTH LOGIN');
|
|
737
737
|
auth.push(Buffer.from(options.user).toString('base64'));
|
|
@@ -924,4 +924,4 @@ exports.refresh = function() {
|
|
|
924
924
|
if (conn.TS < NOW && (!conn.messages || !conn.messages.length))
|
|
925
925
|
Mailer.destroy(F.temporary.smtp[key]);
|
|
926
926
|
}
|
|
927
|
-
};
|
|
927
|
+
};
|
package/package.json
CHANGED
package/pypeline.js
CHANGED
|
@@ -6,7 +6,6 @@ function Pypeline(filename) {
|
|
|
6
6
|
|
|
7
7
|
t.socket = PATH.tmp('pypeline_' + HASH(filename).toString(36) + '.socket');
|
|
8
8
|
t.filename = filename;
|
|
9
|
-
t.callbacks = {};
|
|
10
9
|
t.sockets = [];
|
|
11
10
|
t.processes = [];
|
|
12
11
|
t.current = 0;
|
|
@@ -63,21 +62,9 @@ Pypeline.prototype.init = function() {
|
|
|
63
62
|
});
|
|
64
63
|
|
|
65
64
|
socket.on('end', function() {
|
|
66
|
-
|
|
67
|
-
for (let key in t.callbacks) {
|
|
68
|
-
let callback = t.callbacks[key];
|
|
69
|
-
if (callback.socket === socket) {
|
|
70
|
-
try {
|
|
71
|
-
callbacks.fn('Disconnected');
|
|
72
|
-
} catch {}
|
|
73
|
-
delete t.callbacks[key];
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
|
|
77
65
|
let index = t.sockets.indexOf(socket);
|
|
78
66
|
if (index !== -1)
|
|
79
67
|
t.sockets.splice(index);
|
|
80
|
-
|
|
81
68
|
});
|
|
82
69
|
|
|
83
70
|
let pending = t.pending.splice(0);
|
|
@@ -117,14 +104,6 @@ Pypeline.prototype.close = function() {
|
|
|
117
104
|
t.process.kill(9);
|
|
118
105
|
} catch {}
|
|
119
106
|
|
|
120
|
-
for (let key in t.callbacks) {
|
|
121
|
-
let callback = t.callbacks[key];
|
|
122
|
-
try {
|
|
123
|
-
callbacks.fn('Disconnected');
|
|
124
|
-
} catch {}
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
t.callbacks = null;
|
|
128
107
|
return t;
|
|
129
108
|
};
|
|
130
109
|
|
|
@@ -166,7 +145,6 @@ Pypeline.prototype.run = Pypeline.prototype.restart = function() {
|
|
|
166
145
|
}
|
|
167
146
|
|
|
168
147
|
let args = [];
|
|
169
|
-
let scr = t.filename.includes('\n');
|
|
170
148
|
|
|
171
149
|
if (t.inline)
|
|
172
150
|
args.push('-c');
|
|
@@ -221,4 +199,4 @@ exports.init = function(filename, options, inline) {
|
|
|
221
199
|
}
|
|
222
200
|
|
|
223
201
|
return pypeline;
|
|
224
|
-
};
|
|
202
|
+
};
|
package/tangular.js
CHANGED
|
@@ -96,7 +96,7 @@
|
|
|
96
96
|
|
|
97
97
|
self.template = template;
|
|
98
98
|
|
|
99
|
-
template = template.replace(/\|\|/g, '\
|
|
99
|
+
template = template.replace(/\|\|/g, '\x01');
|
|
100
100
|
|
|
101
101
|
self.variables = {};
|
|
102
102
|
self.commands = [];
|
|
@@ -221,9 +221,9 @@
|
|
|
221
221
|
var ishelperfirst = ishelper && !i;
|
|
222
222
|
index = helper.indexOf('(');
|
|
223
223
|
if (index === -1) {
|
|
224
|
-
helper = 'Thelpers.$execute($helpers,model,\'' + helper + '\',' + (ishelperfirst ? '' : '\
|
|
224
|
+
helper = 'Thelpers.$execute($helpers,model,\'' + helper + '\',' + (ishelperfirst ? '' : '\x07)');
|
|
225
225
|
} else
|
|
226
|
-
helper = 'Thelpers.$execute($helpers,model,\'' + helper.substring(0, index) + '\',' + (ishelperfirst ? '' : '\
|
|
226
|
+
helper = 'Thelpers.$execute($helpers,model,\'' + helper.substring(0, index) + '\',' + (ishelperfirst ? '' : '\x07,') + helper.substring(index + 1);
|
|
227
227
|
helpers[i] = helper;
|
|
228
228
|
}
|
|
229
229
|
} else
|
|
@@ -315,9 +315,9 @@
|
|
|
315
315
|
for (var j = 0; j < cmd.helpers.length; j++) {
|
|
316
316
|
var helper = cmd.helpers[j];
|
|
317
317
|
if (j === 0)
|
|
318
|
-
str = helper.replace('\
|
|
318
|
+
str = helper.replace('\x07', cmd.cmd.trim()).trim();
|
|
319
319
|
else
|
|
320
|
-
str = helper.replace('\
|
|
320
|
+
str = helper.replace('\x07', str.trim());
|
|
321
321
|
}
|
|
322
322
|
builder.push('$tmp=' + str + ';if($tmp!=null)$output+=$tmp;');
|
|
323
323
|
} else
|
|
@@ -406,4 +406,4 @@
|
|
|
406
406
|
Thelpers.empty=Thelpers.def=function(e,n){return e?Thelpers.encode(e):n||'---'};
|
|
407
407
|
Thelpers.currency=function(e,t){switch(typeof e){case'number':return e.currency(t);case'string':return e.parseFloat().currency(t);default:return''}};
|
|
408
408
|
|
|
409
|
-
})(global);
|
|
409
|
+
})(global);
|
package/viewengine.js
CHANGED
|
@@ -112,7 +112,6 @@ exports.compile = function(name, content, debug = true) {
|
|
|
112
112
|
var isCOMPILATION = false;
|
|
113
113
|
var builderTMP = '';
|
|
114
114
|
var sectionName = '';
|
|
115
|
-
var components = {};
|
|
116
115
|
var text;
|
|
117
116
|
|
|
118
117
|
while (command) {
|
|
@@ -912,4 +911,4 @@ View.prototype.render = function(name, model, ispartial = false) {
|
|
|
912
911
|
return content;
|
|
913
912
|
};
|
|
914
913
|
|
|
915
|
-
exports.View = View;
|
|
914
|
+
exports.View = View;
|