-
Notifications
You must be signed in to change notification settings - Fork 289
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
feat: refresh self protocols on team refresh #15897
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #15897 +/- ##
=======================================
Coverage 44.53% 44.53%
=======================================
Files 674 674
Lines 22756 22758 +2
Branches 5175 5175
=======================================
+ Hits 10134 10135 +1
- Misses 11325 11326 +1
Partials 1297 1297 |
@@ -156,6 +157,7 @@ export class TeamRepository extends TypedEventEmitter<Events> { | |||
try { | |||
await this.getTeam(); | |||
await this.updateFeatureConfig(); | |||
this.emit('teamRefreshed'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion: maybe we could narrow down the scope of this event to just featureConfigUpdated
and move it to the updateFeatureConfig
function (this way we are sure this event will emit even if we just update the config and not the entire team). WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updateFeatureConfig
is called every time any of the feature is updated though, so we would refresh protocols too often in my opinion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hummm I see. ok then, fine for now 👍
Description
Makes user refresh self supported protocols after team (and its whole feature list) was refreshed. This happens every 24h.