fix props checking

This commit is contained in:
srgooglo 2022-11-14 18:42:03 +00:00
parent fd99ec2f2b
commit 1571aa09b9

View File

@ -13,7 +13,7 @@ export default (props) => {
let [userData, setUserData] = React.useState(props.user)
const fetchUser = async () => {
if (!props.user_id || props.username) {
if (!props.user_id && !props.username) {
console.error("Cannot fetch user data without user_id or username")
return false
}