Return early in Scratch.show if there's no scratch windows

This commit is contained in:
Ole Jørgen Brønner
2018-06-23 19:20:17 +02:00
parent c7e4d99a35
commit c18ce14e00

View File

@@ -57,9 +57,14 @@ function toggleScratch() {
function show() {
let windows = getScratchWindows();
if (windows.length === 0) {
return;
}
TopBar.show();
windows.slice().reverse()
. map(function(meta_window) {
.map(function(meta_window) {
meta_window.unminimize();
meta_window.make_above();
meta_window.get_compositor_private().show();