Fix TypeError (reading 'moderated') (#722)
Co-authored-by: ekzyis <ek@stacker.news>
This commit is contained in:
parent
c23799be81
commit
3a0c50566b
|
@ -103,7 +103,7 @@ export function PostForm ({ type, sub, children }) {
|
||||||
<Alert className='position-absolute' style={{ top: '-6rem' }} variant='danger' onClose={() => setErrorMessage(undefined)} dismissible>
|
<Alert className='position-absolute' style={{ top: '-6rem' }} variant='danger' onClose={() => setErrorMessage(undefined)} dismissible>
|
||||||
{errorMessage}
|
{errorMessage}
|
||||||
</Alert>}
|
</Alert>}
|
||||||
<SubSelect prependSubs={['pick territory']} className='w-auto d-flex' noForm sub={sub?.name} hint={sub.moderated && 'this territory is moderated'} />
|
<SubSelect prependSubs={['pick territory']} className='w-auto d-flex' noForm sub={sub?.name} hint={sub?.moderated && 'this territory is moderated'} />
|
||||||
|
|
||||||
{postButtons}
|
{postButtons}
|
||||||
<div className='d-flex mt-4'>
|
<div className='d-flex mt-4'>
|
||||||
|
@ -170,7 +170,7 @@ export default function Post ({ sub }) {
|
||||||
<SubInfo />
|
<SubInfo />
|
||||||
</span>
|
</span>
|
||||||
}
|
}
|
||||||
hint={sub.moderated && 'this territory is moderated'}
|
hint={sub?.moderated && 'this territory is moderated'}
|
||||||
/>}
|
/>}
|
||||||
</PostForm>
|
</PostForm>
|
||||||
</>
|
</>
|
||||||
|
|
Loading…
Reference in New Issue