From e2b4088b25551316d373eae6a4e4cc2293801058 Mon Sep 17 00:00:00 2001 From: Peter Kozak Date: Thu, 28 Mar 2013 09:12:05 +0100 Subject: parent accounts fixed --- app/controllers/call_forwards_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/call_forwards_controller.rb b/app/controllers/call_forwards_controller.rb index 858ed12..cdf6c06 100644 --- a/app/controllers/call_forwards_controller.rb +++ b/app/controllers/call_forwards_controller.rb @@ -136,7 +136,7 @@ class CallForwardsController < ApplicationController phone_number_destination, ] - if @parent.try(:voicemail_accounts) + if @parent.class == SipAccount || @parent.class == User || @parent.class == Tenant @parent.voicemail_accounts.each do |voicemail_account| call_forwards_destination = CallForwardingDestination.new() call_forwards_destination.id = "#{voicemail_account.id}:VoicemailAccount" -- cgit v1.2.3