Skip to content

Commit a40017e

Browse files
committed
Refactor error handling in Color Splasher script by removing redundant exception block for Revit application access.
1 parent c3eb5fe commit a40017e

File tree

1 file changed

+0
-8
lines changed
  • extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton

1 file changed

+0
-8
lines changed

extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/script.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1957,14 +1957,6 @@ def launch_color_splasher():
19571957
error_msg.MainContent = "Please ensure you have a Revit project open and try again."
19581958
error_msg.Show()
19591959
return
1960-
1961-
try:
1962-
except (AttributeError, RuntimeError, Exception) as e:
1963-
error_msg = UI.TaskDialog("Color Splasher Error")
1964-
error_msg.MainInstruction = "Unable to access Revit application"
1965-
error_msg.MainContent = "Please ensure you have a Revit project open and try again."
1966-
error_msg.Show()
1967-
return
19681960

19691961
sel_view = get_active_view(doc)
19701962
if sel_view != 0:

0 commit comments

Comments
 (0)