Skip to content
Snippets Groups Projects
Commit e6df308c authored by Rodrigo Nascimento's avatar Rodrigo Nascimento
Browse files

Prevent erros on travis

parent fc536369
No related branches found
No related tags found
No related merge requests found
...@@ -41,6 +41,9 @@ RocketChat.models.Subscriptions.cache.hasOne('Users', { ...@@ -41,6 +41,9 @@ RocketChat.models.Subscriptions.cache.hasOne('Users', {
return subscription.t === 'd'; return subscription.t === 'd';
}, },
transform(subscription, user) { transform(subscription, user) {
if (user == null || subscription == null) {
return undefined;
}
// Prevent client cache for old subscriptions with new names // Prevent client cache for old subscriptions with new names
// Cuz when a user change his name, the subscription's _updateAt // Cuz when a user change his name, the subscription's _updateAt
// will not change // will not change
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment