Skip to content

Commit ab1d815

Browse files
committed
Only advertise tool actions with a document
1 parent 6f61399 commit ab1d815

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

editor/src/communication/dispatcher.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,9 @@ impl Dispatcher {
134134
list.extend(self.message_handlers.input_preprocessor_message_handler.actions());
135135
list.extend(self.message_handlers.input_mapper_message_handler.actions());
136136
list.extend(self.message_handlers.global_message_handler.actions());
137-
list.extend(self.message_handlers.tool_message_handler.actions());
137+
if self.message_handlers.portfolio_message_handler.active_document().is_some() {
138+
list.extend(self.message_handlers.tool_message_handler.actions());
139+
}
138140
list.extend(self.message_handlers.portfolio_message_handler.actions());
139141
list
140142
}

0 commit comments

Comments
 (0)