diff --git a/app/models/sort_title.rb b/app/models/sort_title.rb index 55ff31337..acc79b939 100644 --- a/app/models/sort_title.rb +++ b/app/models/sort_title.rb @@ -6,6 +6,8 @@ def initialize(title) end def alphabetical + return if @title.blank? + title = @title.downcase title = title.gsub(/^an(?:[[:space:]])/, '') .gsub(/^a(?:[[:space:]])/, '')