Simplix-Softworks / SimplixStorage

Library to store data in a better way
Apache License 2.0
138 stars 25 forks source link

Memory Leaks + Use EntrySet instead KeySet #34

Closed 360matt closed 3 years ago

360matt commented 3 years ago

I have found a little bug:

In de.leonhard.storage.Json at method write() : The writer was not closed.

And, In de.leonhard.storage.util.JsonUtils at getJsonFromMap() : Use Map.Entry (one time loop) instead of KeySet (loop + find)

KotlinFactory commented 3 years ago

Hey, thanks for reporting this, you are absolutely right about the getJsonFromMap method, I will correct that! The writer is being closed by the @Cleanup annotation from lombok.

Regards, Leonhard

KotlinFactory commented 3 years ago

Done, thanks again for the feedback!