Skip to content

Commit

Permalink
Call the on_error handler with the correct number of arguments.
Browse files Browse the repository at this point in the history
Fixes an exception:
```
wrong number of arguments (given 3, expected 2)
```

Alternatively we could have called `pipeline&.context&.on_error` which takes 3 args.
  • Loading branch information
jcoyne committed Jan 6, 2024
1 parent 8b9e584 commit 908f2ed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/services/spotlight/etl/solr_loader.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def send_one(document, pipeline)
data: [document].to_json,
headers: { 'Content-Type' => 'application/json' }
rescue StandardError => e
pipeline&.on_error(self, e, document.to_json)
pipeline&.on_error(e, document.to_json)
end

def blacklight_solr
Expand Down

0 comments on commit 908f2ed

Please sign in to comment.