Skip to content

Commit

Permalink
raise an error if the insertion index was not found
Browse files Browse the repository at this point in the history
  • Loading branch information
Yanis42 committed Jul 21, 2024
1 parent 179f234 commit 5f934d5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fast64_internal/oot/exporter/decomp_edit/scene_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,8 @@ def getInsertionIndex(self, index: Optional[int] = None) -> int:
if self.sceneEnumValues[i] == ootEnumSceneID[currentIndex][0]:
return i + 1

# if the index hasn't been found yet, do it again but decrement the index
return self.getInsertionIndex(currentIndex - 1)
# if the index hasn't been found yet, throw an error
raise PluginError("ERROR: the insertion index was not found")

def getIndex(self) -> int:
"""Returns the selected scene index if it's a vanilla one, else returns the custom scene index"""
Expand Down

0 comments on commit 5f934d5

Please sign in to comment.