Some fixes from the scalatra-angularjs-portlet