changed our syntax so that the find :first commands actually work :)
This commit is contained in:
parent
77420bcb09
commit
c523c17111
3 changed files with 3 additions and 3 deletions
|
@ -23,7 +23,7 @@ class SessionsController < ApplicationController
|
||||||
@user = User.new
|
@user = User.new
|
||||||
|
|
||||||
@connor = User.find(555629996)
|
@connor = User.find(555629996)
|
||||||
@map = Map.find(:first, 5)
|
@map = Map.first(:conditions => [ "id = ?", 5])
|
||||||
|
|
||||||
if @map
|
if @map
|
||||||
respond_with(@user, @session, location: user_map_url(@connor,@map)) do |format|
|
respond_with(@user, @session, location: user_map_url(@connor,@map)) do |format|
|
||||||
|
|
|
@ -40,7 +40,7 @@ class UsersController < ApplicationController
|
||||||
|
|
||||||
# direct them straight to the metamaps manual map.
|
# direct them straight to the metamaps manual map.
|
||||||
@connor = User.find(555629996)
|
@connor = User.find(555629996)
|
||||||
@map = Map.find(:first, 5)
|
@map = Map.first(:conditions => [ "id = ?", 5])
|
||||||
|
|
||||||
if @map
|
if @map
|
||||||
respond_with(@user, location: user_map_url(@connor,@map)) do |format|
|
respond_with(@user, location: user_map_url(@connor,@map)) do |format|
|
||||||
|
|
|
@ -65,7 +65,7 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="footer">
|
<div class="footer">
|
||||||
<% unless Map.find(:first, 7).nil? %>
|
<% unless Map.first(:conditions => [ "id = ?", 7]).nil? %>
|
||||||
<div class="feedback"><%= link_to "Feedback", user_map_path(User.find(555629996), Map.find(7)) %></div>
|
<div class="feedback"><%= link_to "Feedback", user_map_path(User.find(555629996), Map.find(7)) %></div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<div class="legend">
|
<div class="legend">
|
||||||
|
|
Loading…
Reference in a new issue