update to portal.js