chat: reducer handles metadata removal
@@ -7,6 +7,7 @@ export class MetadataReducer {
this.associations(data, state);
this.add(data, state);
this.update(data, state);
+ this.remove(data, state);
}
}
@@ -39,4 +40,13 @@ export class MetadataReducer {
state.associations = metadata;
}
}
+
+ remove(json, state) {
+ let data = _.get(json, 'remove', false);
+ if (data) {
+ let metadata = state.associations;
+ metadata.delete(data["app-path"]);
+ state.associations = metadata;
+ }
+ }
}
\ No newline at end of file
