Skip to content

Commit

Permalink
fix missing association (#128)
Browse files Browse the repository at this point in the history
* fix missing association

* fix tests
  • Loading branch information
vswamidass-sfdc authored Feb 18, 2025
1 parent 5279e25 commit 8692eb5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/models/assistant.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
class Assistant < ApplicationRecord
has_many :chats, dependent: :destroy
belongs_to :user
belongs_to :library, optional: true
enum status: { development: 0, ready: 1 }
validates :name, presence: true
validates :slack_channel_name, uniqueness: true, allow_blank: true
Expand Down
1 change: 1 addition & 0 deletions spec/factories/assistants.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
llm_prompt { 'MyText' }
libraries { '1' }
input { 'some input' }
name { 'Test Assistant' }
association :user
end
end

0 comments on commit 8692eb5

Please sign in to comment.