TAMULib / SAGE

Search Aggregation Engine
MIT License
6 stars 2 forks source link

Issue 476: Sort order toggle button appends value=undefined to URL, breaking the search. #477

Closed kaladay closed 1 year ago

kaladay commented 1 year ago

Description

There are several areas where the is undefined logic can be improved. Fixing these does not solve the problem and such changes have been omitted.

The problem is that the form has an initial value that is undefined. When the form gets submitted, via a search button click or a sort button click, then the undefined gets translated into the string 'undefined'.

The immediate solution is to always initialize the value as an empty string before processing any of the URL arguments on first load.

Fixes #476

Type of change

Please delete options that are not relevant.

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

Checklist:

coveralls commented 1 year ago

Coverage Status

Coverage decreased (-0.01%) to 45.192% when pulling 99f2cd92803bd405f01715cc3fa2af84fd0b33e1 on 476-value_undefined into 6956968e2b8ab2a9c017555af2533e48632d9ff3 on main.