lib/webconsole/lib/module.rb in webconsole-0.1.14 vs lib/webconsole/lib/module.rb in webconsole-0.1.15

- old
+ new

@@ -51,9 +51,15 @@ WINDOW_ID_FOR_PLUGIN_SCRIPT = File.join(APPLESCRIPT_DIRECTORY, "window_id_for_plugin.scpt") def self.window_id_for_plugin(name) result = self.run_applescript(WINDOW_ID_FOR_PLUGIN_SCRIPT, [name]) result.chomp! + + if result.empty? + # TODO: Remove this when doing `run_applescript` refactor + return nil + end + return result end SPLIT_ID_IN_WINDOW_SCRIPT = File.join(APPLESCRIPT_DIRECTORY, "split_id_in_window.scpt") def self.split_id_in_window(window_id, pluginName = nil)