stab-hotfix
This commit is contained in:
parent
cb5c78790b
commit
ed2b4ebfbf
|
@ -538,7 +538,7 @@ export const FullArticle = (props: Props) => {
|
|||
{(triggerRef: (el) => void) => (
|
||||
<div class={styles.shoutStatsItem} ref={triggerRef}>
|
||||
<a
|
||||
href={getPagePath(router, 'edit', { shoutId: props.article.id.toString() })}
|
||||
href={getPagePath(router, 'edit', { shoutId: props.article?.id.toString() })}
|
||||
class={styles.shoutStatsItemInner}
|
||||
>
|
||||
<Icon name="pencil-outline" class={styles.icon} />
|
||||
|
|
|
@ -54,7 +54,7 @@ export const AuthorBadge = (props: Props) => {
|
|||
requireAuthentication(() => {
|
||||
openPage(router, 'inbox')
|
||||
changeSearchParams({
|
||||
initChat: props.author.id.toString(),
|
||||
initChat: props.author?.id.toString(),
|
||||
})
|
||||
}, 'discussions')
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ export const AuthorCard = (props: Props) => {
|
|||
requireAuthentication(() => {
|
||||
openPage(router, 'inbox')
|
||||
changeSearchParams({
|
||||
initChat: props.author.id.toString(),
|
||||
initChat: props.author?.id.toString(),
|
||||
})
|
||||
}, 'discussions')
|
||||
}
|
||||
|
|
|
@ -60,7 +60,7 @@ export const Draft = (props: Props) => {
|
|||
<div class={styles.actions}>
|
||||
<a
|
||||
class={styles.actionItem}
|
||||
href={getPagePath(router, 'edit', { shoutId: props.shout.id.toString() })}
|
||||
href={getPagePath(router, 'edit', { shoutId: props.shout?.id.toString() })}
|
||||
>
|
||||
{t('Edit')}
|
||||
</a>
|
||||
|
|
|
@ -328,7 +328,7 @@ export const ArticleCard = (props: ArticleCardProps) => {
|
|||
<Popover content={t('Edit')} disabled={isActionPopupActive()}>
|
||||
{(triggerRef: (el) => void) => (
|
||||
<div class={styles.shoutCardDetailsItem} ref={triggerRef}>
|
||||
<a href={getPagePath(router, 'edit', { shoutId: props.article.id.toString() })}>
|
||||
<a href={getPagePath(router, 'edit', { shoutId: props.article?.id.toString() })}>
|
||||
<Icon name="pencil-outline" class={clsx(styles.icon, styles.feedControlIcon)} />
|
||||
<Icon
|
||||
name="pencil-outline-hover"
|
||||
|
|
|
@ -18,7 +18,7 @@ import styles from '../styles/Create.module.scss'
|
|||
const handleCreate = async (layout: LayoutType) => {
|
||||
const shout = await apiClient.createArticle({ article: { layout: layout } })
|
||||
redirectPage(router, 'edit', {
|
||||
shoutId: shout.id.toString(),
|
||||
shoutId: shout?.id.toString(),
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user