make compatible with browserify