Add "rentable type" to rentables
[cs356-p2-videostore.git] / app / controllers / game_controller.rb
index 50f6a95..1b57435 100644 (file)
@@ -23,6 +23,7 @@ class GameController < ApplicationController
   def create
     # A new rentable must be created whenever we create a new game
     @rentable = Rentable.new
+    @rentable.rtype = 'game'
     @rentable.save
     @game = Game.new(params[:game])
     @game.rentable_id = @rentable.id