Skip to content

Commit

Permalink
Cleanup zstd processor
Browse files Browse the repository at this point in the history
  • Loading branch information
ArchLeaders committed Jan 15, 2024
1 parent fd29ce6 commit fe87204
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/TotkZstd.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,19 +60,17 @@ public void Reprocess(IEditorFile handle)
WriteEditorFile baseWrite = handle.Write;
handle.Write = (data) => {
if (handle.Name.EndsWith(".bcett.byml.zs")) {
data = _bcettCompressor.Wrap(data);
baseWrite(_bcettCompressor.Wrap(data));
}
else if (handle.Name.EndsWith(".pack.zs")) {
data = _packCompressor.Wrap(data);
baseWrite(_packCompressor.Wrap(data));
}
else if (handle.Name.EndsWith(".rsizetable.zs")) {
data = _defaultCompressor.Wrap(data);
baseWrite(_defaultCompressor.Wrap(data));
}
else {
data = _commonCompressor.Wrap(data);
baseWrite(_commonCompressor.Wrap(data));
}
baseWrite(data);
};
}

Expand Down

0 comments on commit fe87204

Please sign in to comment.