uclibs / scholar_uc_legacy

Source code for Scholar@UC up to version 3.x. Replaced by ucrate
Other
5 stars 1 forks source link

Trailing whitespace breaks user search #1910

Closed asleepysheepy closed 6 years ago

asleepysheepy commented 6 years ago

Descriptive summary

When searching users on the people page in scholar trailing white space in the search string cause no user to be returned

When searching "Katie"

image

When searching "Katie "

image

Steps to reproduce the behavior

  1. Go to users page in scholar
  2. search for an existing user, adding a space after the name
changy66 commented 6 years ago

In the 'app/views/hyrax/users/_search_form.html.erb', I changed 'params[:uq]' to 'params[:uq].strip', it doesn't work correctly. looks like it still take "Katie " as input but it showed "Ketie" in the field. image

Maybe we need to change some files in the gem?

hortongn commented 6 years ago

Moved this issue to https://github.com/uclibs/ucrate/issues/277