adding logging to core.js