proper removal of pJS to avoid mouse events' errors