remove console.log
refactor public js