Activity
presence_in
can be nice to quiet down those ternaries and avoid the double params[:sort]
which makes the line busy:
params[:sort].presence_in(%w{ name position office age start_date }) || "name"
presence_in
can be nice to quiet down those ternaries and avoid the double params[:sort]
which makes the line busy:
params[:sort].presence_in(%w{ name position office age start_date }) || "name"