Skip to content

Commit

Permalink
Merge pull request #3481 from manyfold3d/order-libraries-by-name
Browse files Browse the repository at this point in the history
Order libraries by name, by default
  • Loading branch information
Floppy authored Jan 24, 2025
2 parents 466fe90 + 8a8298a commit ebe8dfd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/library.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class Library < ApplicationRecord
validates :s3_access_key_id, presence: true, if: -> { storage_service == "s3" }
validates :s3_secret_access_key, presence: true, if: -> { storage_service == "s3" }

default_scope { order(:path) }
default_scope { order(:name) }

def name
self[:name] || (path ? File.basename(path) : "")
Expand Down

0 comments on commit ebe8dfd

Please sign in to comment.