Make tomahawk.js more portable