Starting to rejig it

This commit is contained in:
n1073645 2019-12-02 14:15:21 +00:00
parent 3fa3c31e31
commit 9f3b185f77
40 changed files with 131 additions and 82 deletions

View file

@ -6,6 +6,7 @@
import Operation from "../Operation.mjs";
import {fromBase64, ALPHABET_OPTIONS} from "../lib/Base64.mjs";
import magicObject from "../lib/MagicObject.mjs";
/**
* From Base64 operation
@ -36,7 +37,7 @@ class FromBase64 extends Operation {
value: true
}
];
this.patterns = [
this.checks = new magicObject([
{
match: "^\\s*(?:[A-Z\\d+/]{4})+(?:[A-Z\\d+/]{2}==|[A-Z\\d+/]{3}=)?\\s*$",
flags: "i",
@ -102,7 +103,7 @@ class FromBase64 extends Operation {
flags: "i",
args: ["./0-9A-Za-z", true]
},
];
]);
}
/**