Fixed Params.permit and added tests.