MDL-33552 - portfolio api E_STRICT fixes