@selfcommunity/react-ui 0.10.0-alpha.6 → 0.10.0-alpha.7
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.
|
@@ -91,7 +91,7 @@ function EventHeader(inProps) {
|
|
|
91
91
|
// INTL
|
|
92
92
|
const intl = (0, react_intl_1.useIntl)();
|
|
93
93
|
// CONST
|
|
94
|
-
const isEventAdmin = (0, react_1.useMemo)(() => scUserContext.user && (scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by.id) === scUserContext.user.id, [scUserContext.user, scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by
|
|
94
|
+
const isEventAdmin = (0, react_1.useMemo)(() => scUserContext.user && scEvent && (scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by.id) === scUserContext.user.id, [scUserContext.user, scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by]);
|
|
95
95
|
const isEventFinished = (0, react_1.useMemo)(() => (0, events_1.checkEventFinished)(scEvent), [scEvent]);
|
|
96
96
|
/**
|
|
97
97
|
* Handles callback subscribe/unsubscribe event
|
|
@@ -89,7 +89,7 @@ export default function EventHeader(inProps) {
|
|
|
89
89
|
// INTL
|
|
90
90
|
const intl = useIntl();
|
|
91
91
|
// CONST
|
|
92
|
-
const isEventAdmin = useMemo(() => scUserContext.user && (scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by.id) === scUserContext.user.id, [scUserContext.user, scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by
|
|
92
|
+
const isEventAdmin = useMemo(() => scUserContext.user && scEvent && (scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by.id) === scUserContext.user.id, [scUserContext.user, scEvent === null || scEvent === void 0 ? void 0 : scEvent.managed_by]);
|
|
93
93
|
const isEventFinished = useMemo(() => checkEventFinished(scEvent), [scEvent]);
|
|
94
94
|
/**
|
|
95
95
|
* Handles callback subscribe/unsubscribe event
|