Project

General

Profile

Actions

Bug #7418

closed

Capitals used for column-based activerecord errors

Added by Lukas Zapletal over 9 years ago. Updated over 5 years ago.

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

Description

We should de-capitalize the following lines:

[lzap@lzapx foreman]$ ack errors.add | grep -v :base | grep -E '"[A-Z]'
app/services/tax_host.rb:134:        taxonomy.errors.add(taxable_type.tableize, _("You cannot remove %s that are used by hosts or inherited.") % taxable_type.tableize.humanize.downcase)
app/models/filter.rb:10:      record.errors.add(:search, _("Invalid search query: %s") % e)
app/models/nic/base.rb:56:            errors.add(attr, _("Can't use the same value as the primary interface"))
app/models/user.rb:469:      errors.add :role_ids, _("You can't assign some of roles you selected")
app/models/user.rb:476:      errors.add :admin, _("You can't change Administrator flag")
app/models/user.rb:489:      errors.add :default_location, _("Default locations need to be user locations first")
app/models/user.rb:495:      errors.add :default_organization, _("Default organizations need to be user organizations first")
app/models/concerns/orchestration/dhcp.rb:127:      errors.add(:ip, _("Does not match selected Subnet"))
app/models/external_usergroup.rb:37:    errors.add :auth_source_id, _("LDAP error - %{message}") % { :message => e.message }

Easy to fix.

Actions #1

Updated by Dominic Cleal over 9 years ago

  • Category set to Rails
Actions #2

Updated by Lukas Zapletal over 9 years ago

  • Assignee set to Lukas Zapletal
  • translation missing: en.field_release set to 21
Actions #3

Updated by The Foreman Bot over 9 years ago

  • Status changed from New to Ready For Testing
  • Target version set to 1.7.3
  • Pull request https://github.com/theforeman/foreman/pull/1755 added
  • Pull request deleted ()
Actions #4

Updated by Lukas Zapletal over 9 years ago

It's been a while when I filed a core PR...

https://github.com/theforeman/foreman/pull/1755

Actions #5

Updated by Lukas Zapletal over 9 years ago

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

Also available in: Atom PDF