fix for r.js optimization