Closed matt-bernhardt closed 4 years ago
CodeClimate is flagging 7 instances of things being too long, one of which is the hours loader object itself. I'm open to feedback that this needs to be structured differently, but I'm not sure about getting the overall file to under 250 lines. I don't know that we've had a discussion about this sort of metric and its usefulness, so maybe we can do that soonish?
Status
Use labels (
review needed
,in progress
, orpaused
) to declare statusWhat does this PR do?
This will do two things, if approved:
Move the hours loader out of a separate repository, and into this parent theme (which is where it is invoked anyway). This will include moving some libraries into the repo, such as underscore and moment.
Updates that hours loader to cope with the new data format coming out of the Sheets API v4.
Helpful background context (if appropriate)
This change is related to MITLibraries/mitlib-pull-hours#5 - which is updating the Harvester to pull data from the Sheets API v4.
When merged, we will be able to empty out (or delete altogether) two other repos: https://github.com/MITLibraries/libhours-buildjson (directory needed, but nothing else) https://github.com/MITLibraries/libhours (all these files are either no longer needed, or moved into this theme)
How can a reviewer manually see the effects of these changes?
This branch has been deployed to the staging site, and all traces of the old hours loader have been removed.
What are the relevant tickets?
Todo:
Requires new or updated plugins, themes, or libraries?
YES (although they are in this repo)
Requires change to deploy process?
NO