Permit parameters without root key
This commit is contained in:
parent
667d6a028c
commit
8b07c46acd
|
|
@ -28,6 +28,6 @@ class MatchScoresController < ApplicationController
|
||||||
|
|
||||||
# Only allow a trusted parameter "white list" through.
|
# Only allow a trusted parameter "white list" through.
|
||||||
def match_score_params
|
def match_score_params
|
||||||
params.require(:match_score).permit(:points)
|
params.permit(:points)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -26,6 +26,6 @@ class TeamsController < ApplicationController
|
||||||
end
|
end
|
||||||
|
|
||||||
def team_params
|
def team_params
|
||||||
params.require(:team).permit(:name)
|
params.permit(:name)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -48,6 +48,6 @@ class TournamentsController < ApplicationController
|
||||||
end
|
end
|
||||||
|
|
||||||
def tournament_params
|
def tournament_params
|
||||||
params.require(:tournament).permit(:name, :description, :public, :teams)
|
params.permit(:name, :description, :public, :teams)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue