[RasPlex][ENH] Profiler : fixing some issues when exiting Plex app.