Skip to content
This repository has been archived by the owner on May 14, 2024. It is now read-only.

Refactor #23

Merged
merged 3 commits into from
Nov 11, 2021
Merged

Refactor #23

merged 3 commits into from
Nov 11, 2021

Conversation

JosiahBull
Copy link
Owner

Description

Refactored some code out into submodules, helping to reduce bloat. Especially the testing code.
Configuration received a major rework, and as part of that I bundled fixing #8.

Closes #8
Closes #22

Checklist:

  • I have run clippy and followed all lints.
  • I have run rust fmt already.
  • Tests have been written for my new code.
  • Comments have been written for my code.
  • The docker-compose file is not broken.
  • The readme does not need updating.

…her than a bunch of lazy_statics.

Advantages
- Easier to test with
- More configurable
- Drop the lazy_static dependency

Disadvantages:
- Cumbersome, have to pass in the config to every function now.
- Potentially slower, as the code has to process an extra step in the request guard.

All in all, I believe this is a worthwhile tradeoff.
@JosiahBull JosiahBull added enhancement New feature or request refactor labels Nov 11, 2021
@JosiahBull JosiahBull added this to the 0.2-Beta milestone Nov 11, 2021
@JosiahBull JosiahBull merged commit 97db92f into 0.2-dev Nov 11, 2021
@JosiahBull JosiahBull deleted the refactor branch November 11, 2021 22:23
@JosiahBull JosiahBull mentioned this pull request Nov 12, 2021
6 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request refactor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant