130-fix-empty-relay-issue #131

Merged
eugene merged 7 commits from 130-fix-empty-relay-issue into staging 2024-08-07 15:27:20 +00:00
Owner

Fixes #30.

Includes a refactor of the relevant section in the MetadataController.

MetadataController and NostrController use different types when dealing with User Relays and going forward it would be good to align approaches. Otto confirmed that it's in the post-MVP roadmap.

Current Limitations

  • The default Sigit relay appears as part of User relays. Instead, it should be separated and a new section should be added called 'App Relay'.
Fixes [#30]([https://git.nostrdev.com/sigit/sigit.io/issues/130]). Includes a refactor of the relevant section in the `MetadataController`. `MetadataController` and `NostrController` use different types when dealing with User Relays and going forward it would be good to align approaches. Otto confirmed that it's in the post-MVP roadmap. **Current Limitations** - The default Sigit relay appears as part of User relays. Instead, it should be separated and a new section should be added called 'App Relay'.
eugene added 2 commits 2024-08-07 13:09:03 +00:00
eugene added 1 commit 2024-08-07 14:43:04 +00:00
eugene added 1 commit 2024-08-07 14:49:21 +00:00
eugene added 2 commits 2024-08-07 14:55:30 +00:00
This reverts commit 7e420ef583.
Merge branch 'staging' into 130-fix-empty-relay-issue
Some checks failed
Open PR on Staging / audit_and_check (pull_request) Failing after 32s
3f5451b265
enes requested changes 2024-08-07 15:15:25 +00:00
@ -7,0 +8,4 @@
* Number of milliseconds in one week.
* Calc based on: 7 * 24 * 60 * 60 * 1000
*/
export const ONE_WEEK_IN_MS: number = 604800000
Member

we should use this const instead of const oneWeekInMS = 7 * 24 * 60 * 60 * 1000 // Number of milliseconds in one week at

const oneWeekInMS = 7 * 24 * 60 * 60 * 1000 // Number of milliseconds in one week

we should use this const instead of `const oneWeekInMS = 7 * 24 * 60 * 60 * 1000 // Number of milliseconds in one week` at https://git.nostrdev.com/sigit/sigit.io/src/commit/c1a6ac246b719739ee7e0eb4d7e09ea10bc64ce1/src/controllers/MetadataController.ts#L130
eugene marked this conversation as resolved
@ -0,0 +6,4 @@
import { RelayMap, RelaySet } from '../types'
const READ_MARKER = "read"
const WRITE_MARKET = "write"
Member

small typo

small typo
eugene marked this conversation as resolved
@ -0,0 +75,4 @@
[SIGIT_RELAY]: { write: true, read: true }
})
const isOlderThanOneWeek = (cachedAt: number) => {
Member

Maybe we can use this function as an util, it's used in MetadataContoller.ts too?

Maybe we can use this function as an util, it's used in `MetadataContoller.ts` too?
eugene marked this conversation as resolved
eugene added 1 commit 2024-08-07 15:24:38 +00:00
refactor: post-PR review changes
Some checks failed
Open PR on Staging / audit_and_check (pull_request) Failing after 33s
2acb353535
eugene merged commit f49a9e0b40 into staging 2024-08-07 15:27:20 +00:00
eugene deleted branch 130-fix-empty-relay-issue 2024-08-07 15:27:20 +00:00
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sigit/sigit.io#131
No description provided.