Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

skip search/sort when search term is empty #40

Merged
merged 1 commit into from
Mar 15, 2018

Conversation

hozefaj
Copy link
Contributor

@hozefaj hozefaj commented Mar 15, 2018

What:
when the search term is empty, then skipping all operations and returning the original input

Why:
since the matchSorter perform sort, it changes the input even when nothing is searched. This skip step now prevents that from happening.

How:

Checklist:

  • Documentation
  • Tests
  • Ready to be merged
  • Added myself to contributors table

@codecov
Copy link

codecov bot commented Mar 15, 2018

Codecov Report

Merging #40 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master    #40   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files           1      1           
  Lines         145    146    +1     
  Branches       39     40    +1     
=====================================
+ Hits          145    146    +1
Impacted Files Coverage Δ
src/index.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2800b57...0666227. Read the comment docs.

@hozefaj
Copy link
Contributor Author

hozefaj commented Mar 15, 2018

Fixes issue #39

@hozefaj
Copy link
Contributor Author

hozefaj commented Mar 15, 2018

Tried adding myself to the contributors list, but getting the below error. Tried a few things googling but was not able to figure it out, so gave up in the interest of time.

> [email protected] add-contributor /Users/hjodiawalla/Desktop/Misc/match-sorter
> kcd-scripts contributors add

module.js:538
    throw err;
    ^

Error: Cannot find module 'all-contributors-cli/cli'
    at Function.Module._resolveFilename (module.js:536:15)
    at Function.resolve (internal/module.js:18:19)
    at Object.<anonymous> (/Users/hjodiawalla/Desktop/Misc/match-sorter/node_modules/kcd-scripts/dist/scripts/contributors.js:7:33)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)
    at Function.Module.runMain (module.js:676:10)
    at startup (bootstrap_node.js:187:16)
npm ERR! code ELIFECYCLE

@kentcdodds kentcdodds merged commit dcec521 into kentcdodds:master Mar 15, 2018
@kentcdodds
Copy link
Owner

I'll fix the all-contributors thing. Thank you so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants