Skip to content

Commit

Permalink
AreasController内のマジックナンバーに変数を使って名前を付けた
Browse files Browse the repository at this point in the history
  • Loading branch information
dowdiness committed Mar 6, 2024
1 parent df2f315 commit 5a63716
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/controllers/api/users/areas_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

class API::Users::AreasController < API::BaseController
def index
# params[:area]がnilの場合は東京都を取得
@users = Area.users(params[:region], params[:area] || '13')
tokyo_area_id = '13'
@users = Area.users(params[:region], params[:area] || tokyo_area_id)
end
end

0 comments on commit 5a63716

Please sign in to comment.