Fix firmware update OCPP command handling and simulation
[e-mobility-charging-stations-simulator.git] / src / charging-station / AuthorizedTagsCache.ts
index d39fbee61e6fa6e27a13fbddbab25dbdffee2d06..0f702047702ce5cc92890f28679a9cafddacf1fc 100644 (file)
@@ -23,10 +23,10 @@ export default class AuthorizedTagsCache {
   }
 
   public getAuthorizedTags(file: string): string[] {
-    if (!this.hasTags(file)) {
+    if (this.hasTags(file) === false) {
       this.setTags(file, this.getAuthorizedTagsFromFile(file));
       // Monitor authorization file
-      !this.FSWatchers.has(file) &&
+      this.FSWatchers.has(file) === false &&
         this.FSWatchers.set(
           file,
           FileUtils.watchJsonFile(
@@ -64,6 +64,10 @@ export default class AuthorizedTagsCache {
     return this.getTags(file);
   }
 
+  public deleteAuthorizedTags(file: string): boolean {
+    return this.deleteTags(file);
+  }
+
   private hasTags(file: string): boolean {
     return this.tagsCaches.has(file);
   }