Skip to content

Commit

Permalink
Correctly set defaultData
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverguenther committed Jan 7, 2025
1 parent 9a23dfb commit a8b4dc0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/primer/open_project/forms/autocompleter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def extend_autocomplete_inputs(inputs) # rubocop:disable Metrics/AbcSize
inputs[:classes] = "ng-select--primerized #{@input.invalid? ? '-error' : ''}"
inputs[:inputName] ||= builder.field_name(@input.name)
inputs[:labelForId] ||= builder.field_id(@input.name)
inputs[:defaultData] ||= true
inputs[:defaultData] = true unless inputs.key?(:defaultData)

if inputs.delete(:decorated)
inputs[:items] = @input.select_options.map(&:to_h)
Expand Down

0 comments on commit a8b4dc0

Please sign in to comment.