refactored editor.js
fix