Project

General

Profile

Refactor #3158

Remove rescues from try calls where method doesn't exist

Added by Dominic Cleal about 8 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Normal
Category:
Rails
Target version:
Difficulty:
Triaged:
Bugzilla link:
Fixed in Releases:
Found in Releases:

Description

Via #3129, we added rescues to our try calls in app/helpers/compute_resources_vms_helper.rb as the method may not exist. Rails 4.0's #try will return nil instead of throwing an error, so these can be removed.


Related issues

Related to Foreman - Tracker #3157: Rails 4.1 upgrade tasksClosed2013-09-27

Related to Foreman - Bug #3129: unable to show EC2 vm infoClosed2013-09-20

Associated revisions

Revision d468c1bc (diff)
Added by Kavita Gaikwad almost 5 years ago

fixes #3158 - Remove rescues from try calls in helper file

In app/helpers/compute_resources_vms_helper.rb, we added rescues to
try calls as the method may not exist with older version of rails.
Now, we have updated rails to 4.x.
In this commit removed rescue block as Rails 4.0's try method
will return nil instead of throwing an error,

History

#1 Updated by Dominic Cleal about 8 years ago

#2 Updated by Dominic Cleal about 8 years ago

  • Related to Bug #3129: unable to show EC2 vm info added

#3 Updated by Kavita Gaikwad almost 5 years ago

  • Assignee set to Kavita Gaikwad
  • Target version set to 1.15.6

#4 Updated by The Foreman Bot almost 5 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/4085 added

#5 Updated by Kavita Gaikwad almost 5 years ago

  • Target version changed from 1.15.6 to 1.15.4

#6 Updated by Kavita Gaikwad almost 5 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

#7 Updated by Dominic Cleal almost 5 years ago

  • Legacy Backlogs Release (now unused) set to 209

Also available in: Atom PDF