rsl / stringex

Some [hopefully] useful extensions to Ruby’s String class. It is made up of three libraries: ActsAsUrl [permalink solution with better character translation], Unidecoder [Unicode to Ascii transliteration], and StringExtensions [miscellaneous helper methods for the String class].
MIT License
984 stars 158 forks source link

Fix: Rails initializer callbacks used to prevent early loading #216

Open zealot128 opened 1 month ago

zealot128 commented 1 month ago

This fixes a loading issue, as Gems are not supposed to access Rails core classes (such as ActiveRecord::Base), during or before initialization.

See: https://github.com/rails/rails/issues/52740

Not sure about the code, though, as we are not using acts_as_url or Mongoid etc.