mirror of
https://git.kescher.at/CatCatNya/catstodon.git
synced 2024-11-27 11:41:35 +01:00
[Glitch] Do not show drag&drop dialog when not logined
Port 553b169d48
to glitch-soc
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
parent
8ac4165c72
commit
e2315876f4
1 changed files with 2 additions and 2 deletions
|
@ -303,7 +303,7 @@ class UI extends React.Component {
|
|||
this.dragTargets.push(e.target);
|
||||
}
|
||||
|
||||
if (e.dataTransfer && e.dataTransfer.types.includes('Files') && this.props.canUploadMore) {
|
||||
if (e.dataTransfer && e.dataTransfer.types.includes('Files') && this.props.canUploadMore && this.context.identity.signedIn) {
|
||||
this.setState({ draggingOver: true });
|
||||
}
|
||||
}
|
||||
|
@ -330,7 +330,7 @@ class UI extends React.Component {
|
|||
this.setState({ draggingOver: false });
|
||||
this.dragTargets = [];
|
||||
|
||||
if (e.dataTransfer && e.dataTransfer.files.length >= 1 && this.props.canUploadMore) {
|
||||
if (e.dataTransfer && e.dataTransfer.files.length >= 1 && this.props.canUploadMore && this.context.identity.signedIn) {
|
||||
this.props.dispatch(uploadCompose(e.dataTransfer.files));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue