Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/glacials/splits-io. a speedrunning data store and analysis engine splits.io
Something went wrong. Try again.
12345678910111213141516171819202122232425262728class Games::CategoriesController < ApplicationController before_action :set_game before_action :set_category
def show end
private
def set_game @game = Game.where(shortname: params[:game]).or(Game.where(id: params[:game])).first
if @game.nil? not_found end end
def set_category @category = @game.categories.where(shortname: params[:category]).or( @game.categories.where(id: params[:category]) ).first
if @category.nil? not_found end endend