Fixes for Javascript