Skip to content

Commit

Permalink
Fix returning to trait selectiong reloading the character
Browse files Browse the repository at this point in the history
  • Loading branch information
memelotsqui committed Oct 30, 2023
1 parent 07854ba commit d694bc8
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions src/components/JsonAttributes.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,6 @@ export default function JsonAttributes({jsonSelectionArray}){
} = useContext(SceneContext);
const [index, setIndex] = useState(0);

useEffect(() => {
if (jsonSelectionArray?.length >0)
setSelectedOptions(jsonSelectionArray[0].options)
setIndex(0);
}, [jsonSelectionArray])

const nextJson = async () => {
if (index >= jsonSelectionArray.length -1){
setSelectedOptions(jsonSelectionArray[0].options)
Expand Down

0 comments on commit d694bc8

Please sign in to comment.