This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new b923b96e Ensure something useful is returned [skip ci]
b923b96e is described below

commit b923b96e15e5435e52eb0a3358adc4b1004a661e
Author: Sebb <[email protected]>
AuthorDate: Sat Aug 3 00:07:42 2024 +0100

    Ensure something useful is returned [skip ci]
---
 www/secretary/workbench/views/index.json.rb | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/www/secretary/workbench/views/index.json.rb 
b/www/secretary/workbench/views/index.json.rb
index ae458fc2..d53f2dc7 100644
--- a/www/secretary/workbench/views/index.json.rb
+++ b/www/secretary/workbench/views/index.json.rb
@@ -19,4 +19,10 @@ if index
     mbox: (File.basename(prevmbox, '.yml') if prevmbox),
     messages: Mailbox.new(@mbox).client_headers
   }
+else
+  # ensure we return something usable
+  {
+    mbox: nil,
+    messages: []
+  }
 end

Reply via email to