add function to check if context has specified context
This commit is contained in:
parent
f39acbdd42
commit
fba491592d
|
@ -49,6 +49,10 @@ Plugin.prototype.isContextValid = function() {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Plugin.prototype.hasContext = function(context) {
|
||||||
|
return this.currentContext.includes(context);
|
||||||
|
};
|
||||||
|
|
||||||
Plugin.prototype.loadPlugin = function() {
|
Plugin.prototype.loadPlugin = function() {
|
||||||
if (!this.isContextValid()) {
|
if (!this.isContextValid()) {
|
||||||
console.log(this.acceptedContext);
|
console.log(this.acceptedContext);
|
||||||
|
|
Loading…
Reference in New Issue