Skip to content

Commit

Permalink
Remove 'Name already registered with serializer' error (#6566)
Browse files Browse the repository at this point in the history
  • Loading branch information
devongovett committed Jul 8, 2021
1 parent 938728e commit 2e0bc8e
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions packages/core/core/src/serializer.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,6 @@ const nameToCtor: Map<string, Class<*>> = new Map();
const ctorToName: Map<Class<*>, string> = new Map();

export function registerSerializableClass(name: string, ctor: Class<*>) {
if (nameToCtor.has(name)) {
throw new Error('Name already registered with serializer');
}

if (ctorToName.has(ctor)) {
throw new Error('Class already registered with serializer');
}
Expand Down

0 comments on commit 2e0bc8e

Please sign in to comment.