Skip to content

Commit

Permalink
fix serialization in ContextElementDependency
Browse files Browse the repository at this point in the history
  • Loading branch information
vankop committed Feb 9, 2022
1 parent 2279c5a commit 403057c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions lib/dependencies/ContextElementDependency.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,18 @@ class ContextElementDependency extends ModuleDependency {
}

serialize(context) {
context.write(this.referencedExports);
const { write } = context;
write(this._typePrefix);
write(this._category);
write(this.referencedExports);
super.serialize(context);
}

deserialize(context) {
this.referencedExports = context.read();
const { read } = context;
this._typePrefix = read();
this._category = read();
this.referencedExports = read();
super.deserialize(context);
}
}
Expand Down

0 comments on commit 403057c

Please sign in to comment.