fix platform specific js