Move the portlet preferences injection code in the portlet plugin