From a75a784e8d99ba3a2c5c7b23502818ad883cf5c1 Mon Sep 17 00:00:00 2001 From: Rick Barrette Date: Sat, 3 Sep 2016 09:06:52 -0400 Subject: [PATCH] Update customers_controller.rb --- app/controllers/customers_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/customers_controller.rb b/app/controllers/customers_controller.rb index 77c40e5..c25888b 100644 --- a/app/controllers/customers_controller.rb +++ b/app/controllers/customers_controller.rb @@ -106,7 +106,7 @@ class CustomersController < ApplicationController # Customer view for an issue def view token = CustomerToken.where("token = ? and expires_at > ?", params[:token], Time.now) - if token + if token.first @issue = Issue.find token.first.issue_id @journals = @issue.journals. preload(:details).