Make FlaskPlugin accept factory params