Remove log and unused parameter
This commit is contained in:
parent
6afe242abe
commit
e295df0fdd
1 changed files with 2 additions and 3 deletions
|
|
@ -12,7 +12,6 @@ class Api::V1::FavoritesController < Api::V1::ApiController
|
||||||
elsif Favorite.where(user_id: current_user.id, party_id: party_id).length > 0
|
elsif Favorite.where(user_id: current_user.id, party_id: party_id).length > 0
|
||||||
raise Api::V1::FavoriteAlreadyExistsError
|
raise Api::V1::FavoriteAlreadyExistsError
|
||||||
else
|
else
|
||||||
ap "Create a new favorite"
|
|
||||||
object = {
|
object = {
|
||||||
user_id: current_user.id,
|
user_id: current_user.id,
|
||||||
party_id: favorite_params[:party_id]
|
party_id: favorite_params[:party_id]
|
||||||
|
|
@ -37,6 +36,6 @@ class Api::V1::FavoritesController < Api::V1::ApiController
|
||||||
end
|
end
|
||||||
|
|
||||||
def favorite_params
|
def favorite_params
|
||||||
params.require(:favorite).permit(:id, :party_id)
|
params.require(:favorite).permit(:party_id)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
Loading…
Reference in a new issue