Small fixes post js refactoring