Skip to content

refactor: replace magic batch-time seconds with named constants#2569

Open
miaulalala wants to merge 1 commit intomasterfrom
refactor/batch-time-constants
Open

refactor: replace magic batch-time seconds with named constants#2569
miaulalala wants to merge 1 commit intomasterfrom
refactor/batch-time-constants

Conversation

@miaulalala
Copy link
Copy Markdown
Collaborator

Summary

Adds BATCH_TIME_HOURLY (3600), BATCH_TIME_DAILY (86400), and BATCH_TIME_WEEKLY (604800) constants to UserSettings alongside the existing EMAIL_SEND_* constants. Replaces all bare numeric literals (3600, 3600 * 24, 3600 * 24 * 7) in MailQueueHandler and UserSettings with the new constants.

Test plan

  • UserSettingsTest — green
  • MailQueueHandlerTest — green

🤖 Generated with Claude Code

Add BATCH_TIME_HOURLY/DAILY/WEEKLY to UserSettings alongside the existing
EMAIL_SEND_* constants. Replace all bare 3600 / 3600*24 / 3600*24*7
literals in MailQueueHandler and UserSettings with the new constants.

Signed-off-by: Anna Larch <anna@nextcloud.com>
AI-Assisted-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@miaulalala miaulalala self-assigned this May 6, 2026
@miaulalala miaulalala requested a review from artonge May 6, 2026 22:22
@miaulalala miaulalala added this to the Nextcloud 34 milestone May 6, 2026
@miaulalala miaulalala requested a review from benjaminfrueh May 6, 2026 22:23
@cypress
Copy link
Copy Markdown

cypress Bot commented May 6, 2026

Activity    Run #3706

Run Properties:  status check passed Passed #3706  •  git commit 301442f8e0: refactor: replace magic batch-time seconds with named constants
Project Activity
Branch Review refactor/batch-time-constants
Run status status check passed Passed #3706
Run duration 01m 59s
Commit git commit 301442f8e0: refactor: replace magic batch-time seconds with named constants
Committer Anna
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 1
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 9
View all changes introduced in this branch ↗︎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants