fixing bug in source.js