Mods is done
Fixed memory leaks