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

Allow multiple files to be selected/dropped at once #78

Merged
merged 9 commits into from
May 21, 2024

Conversation

kyle1morel
Copy link
Collaborator

Description

Allow multiple files to be selected/dropped at once

Types of changes

Bug fix (non-breaking change which fixes an issue)

Checklist

  • I have read the CONTRIBUTING doc
  • I have checked that unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

Further comments

@kyle1morel kyle1morel requested a review from wilwong89 as a code owner May 21, 2024 16:51
Copy link

github-actions bot commented May 21, 2024

Coverage Report (Application)

Totals Coverage
Statements: 48.9% ( 598 / 1223 )
Methods: 39% ( 94 / 241 )
Lines: 62.21% ( 400 / 643 )
Branches: 30.68% ( 104 / 339 )

@kyle1morel kyle1morel force-pushed the feature/multi-upload branch from 896bf56 to 3696284 Compare May 21, 2024 20:36
Copy link

Coverage Report (Frontend)

Totals Coverage
Statements: 21.38% ( 574 / 2685 )
Methods: 18.43% ( 94 / 510 )
Lines: 24.47% ( 360 / 1471 )
Branches: 17.05% ( 120 / 704 )

);
}

export async function down(knex: Knex): Promise<void> {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function down has 80 lines of code (exceeds 25 allowed). Consider refactoring.

submissionQuery = await submissionService.getSubmission(testSubmissionId.substring(0, 8).toUpperCase());
} while (submissionQuery);

createSubmission: async (req: Request, res: Response, next: NextFunction) => {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function createSubmission has 96 lines of code (exceeds 25 allowed). Consider refactoring.

@@ -0,0 +1,195 @@
import type { Knex } from 'knex';

export async function up(knex: Knex): Promise<void> {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function up has 94 lines of code (exceeds 25 allowed). Consider refactoring.

* @param {string} activityId Unique activity ID
* @returns {Promise<Activity | null>} The result of running the findFirst operation
*/
getActivity: async (activityId: string) => {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar blocks of code found in 2 locations. Consider refactoring.

submissionQuery = await submissionService.getSubmission(testSubmissionId.substring(0, 8).toUpperCase());
} while (submissionQuery);

createSubmission: async (req: Request, res: Response, next: NextFunction) => {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function createSubmission has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.

Copy link

codeclimate bot commented May 21, 2024

Code Climate has analyzed commit 3696284 and detected 10 issues on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 6
Duplication 4

The test coverage on the diff in this pull request is 27.1% (50% is the threshold).

This pull request will bring the total coverage in the repository to 35.9% (-1.8% change).

View more on Code Climate.

@kyle1morel kyle1morel requested a review from sanjaytkbabu May 21, 2024 22:24
@kyle1morel kyle1morel merged commit 3ccd39f into master May 21, 2024
18 of 22 checks passed
@kyle1morel kyle1morel deleted the feature/multi-upload branch May 21, 2024 22:25
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