Repository navigation
fix: local date reg info for new accounts - #193
Merged
Merged
Conversation
Reviewer's guide (collapsed on small PRs)Reviewer's GuideFixes local registration-date estimation for new accounts by basing boundary fallbacks on the loaded profile date range, keeping IDs and timestamps synchronized with the current data. Flow diagram for profile registration date estimationflowchart TD
A[getUserTime userId] --> B{Matching profile date found?}
B -->|Yes| C[getUserTime with matched date]
B -->|No| D{userId <= first profile ID?}
D -->|Yes| E[getUserTime with first profile date]
D -->|No| F[getUserTime with last profile date]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Hey - I've found 1 issue
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location path="TMessagesProj/src/main/java/tw/nekomimi/nekogram/helpers/ProfileDateHelper.java" line_range="72" />
<code_context>
return getUserTime("~", dateLong);
}
}
- if (userId <= 1000000) {
</code_context>
<issue_to_address>
**issue (bug_risk):** Accounts with IDs above the final JSON entry are displayed as registered after August 2025, because the final entry has date 1755628800 even though an earlier entry has the later date 1764979200. The fallback therefore does not use the latest available profile registration date for new accounts.
**Triggers:** When the account ID is greater than 8461412540.
**Suggested fix:** Use the entry with the maximum registration date for the upper-bound fallback, or ensure the profile data is ordered by date before selecting the final element.
```suggestion
long latestDate = profileDateDataList.get(0).getDate();
for (ProfileDateData data : profileDateDataList) {
if (data.getDate() > latestDate) {
latestDate = data.getDate();
}
}
return getUserTime(">", latestDate * 1000L);
```
</issue_to_address>Sourcery assessment
Approval pending. 1 finding to address first.
Blocking findings: TMessagesProj/src/main/java/tw/nekomimi/nekogram/helpers/ProfileDateHelper.java:72
waifucon
force-pushed
the
fix-date-reg-new-accs
branch
from
October 4, 2026 15:31
c533014 to
5bd8a51
Compare
omg-xtao
approved these changes
Oct 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
reported by nextalone in an nnngram pr: NextAlone/Nnngram#110 (comment)
dropped an hardcoded value.
before:

now:

Summary by Sourcery
Bug Fixes: