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

Improving performance of getting a model/baseModel from entities #718

Merged
merged 1 commit into from
May 6, 2021

Conversation

ntma
Copy link
Contributor

@ntma ntma commented Apr 12, 2021

This PR aims to decrease the complexity of getting a single model/baseModel from the entities list, as described in the issue #717.

Type of PR:

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Build-related changes
  • Documentation
  • Other, please describe: performance fix

Breaking changes:

  • No
  • Yes

Details

It basically replaces the two reduces found here and here with the javascript find to retrieve a model/baseModel from a list of entities.

@codecov
Copy link

codecov bot commented Apr 12, 2021

Codecov Report

Merging #718 (be3a204) into master (7573d2f) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master      #718   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           47        47           
  Lines         1554      1558    +4     
  Branches       260       262    +2     
=========================================
+ Hits          1554      1558    +4     
Impacted Files Coverage Δ
src/database/Database.ts 100.00% <100.00%> (ø)

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 7573d2f...be3a204. Read the comment docs.

@cuebit cuebit added the enhancement New feature or request label May 6, 2021
@cuebit cuebit self-assigned this May 6, 2021
@cuebit
Copy link
Member

cuebit commented May 6, 2021

This is awesome. Thank you for taking the time to address this 👍

@ntma
Copy link
Contributor Author

ntma commented May 8, 2021

@cuebit cheers, happy that I could help 👍

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

Successfully merging this pull request may close these issues.

None yet

2 participants