@selfcommunity/react-core 0.4.50-events.109 → 0.4.50-events.111

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -58,8 +58,7 @@ function useSCFetchEvent({ id = null, event = null, autoSubscribe = true, cacheS
58
58
  .then((event) => {
59
59
  if (autoSubscribe &&
60
60
  authUserId !== null &&
61
- ((event.privacy === types_1.SCEventPrivacyType.PUBLIC && !event.subscription_status) ||
62
- (event.privacy === types_1.SCEventPrivacyType.PRIVATE && event.subscription_status === types_1.SCEventSubscriptionStatusType.INVITED))) {
61
+ ((event.privacy === types_1.SCEventPrivacyType.PUBLIC && !event.subscription_status) || event.subscription_status === types_1.SCEventSubscriptionStatusType.INVITED)) {
63
62
  // Auto subscribe to the event
64
63
  api_services_1.EventService.subscribeToEvent(event.id).then(() => {
65
64
  const updatedEvent = Object.assign(Object.assign({}, event), { subscription_status: types_1.SCEventSubscriptionStatusType.SUBSCRIBED });
@@ -56,8 +56,7 @@ export default function useSCFetchEvent({ id = null, event = null, autoSubscribe
56
56
  .then((event) => {
57
57
  if (autoSubscribe &&
58
58
  authUserId !== null &&
59
- ((event.privacy === SCEventPrivacyType.PUBLIC && !event.subscription_status) ||
60
- (event.privacy === SCEventPrivacyType.PRIVATE && event.subscription_status === SCEventSubscriptionStatusType.INVITED))) {
59
+ ((event.privacy === SCEventPrivacyType.PUBLIC && !event.subscription_status) || event.subscription_status === SCEventSubscriptionStatusType.INVITED)) {
61
60
  // Auto subscribe to the event
62
61
  EventService.subscribeToEvent(event.id).then(() => {
63
62
  const updatedEvent = Object.assign(Object.assign({}, event), { subscription_status: SCEventSubscriptionStatusType.SUBSCRIBED });