mirror of https://github.com/Seich/Beau.git
parent
4bf7a60e9c
commit
56d536a509
|
|
@ -17,3 +17,9 @@ GET /cookies/set:
|
|||
|
||||
GET /status/418:
|
||||
alias: teapot
|
||||
|
||||
POST /post:
|
||||
alias: post
|
||||
formdata:
|
||||
file: $[createReadStream('./github.yml')]
|
||||
|
||||
|
|
|
|||
|
|
@ -53,6 +53,7 @@ class Plugins {
|
|||
}
|
||||
|
||||
replaceDynamicValues(obj) {
|
||||
vm.createContext(this.context);
|
||||
return replaceInObject(obj, val => {
|
||||
let valIsEmpty = val.trim().length === 0;
|
||||
|
||||
|
|
@ -93,8 +94,6 @@ class Plugins {
|
|||
defineDynamicValue(name, fn) {
|
||||
this.registry.dynamicValues.push({ name, fn });
|
||||
this.context[name] = fn;
|
||||
|
||||
vm.createContext(this.context);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue