From 6922824a5edec7b290e114a36889b0056958ed2a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Dorian=20Mari=C3=A9?= <dorian@dorianmarie.com>
Date: Thu, 12 Sep 2024 20:04:30 +0200
Subject: [PATCH] Allows setting headings to nil

Just skips the whole initialization of headings
---
 lib/terminal-table/table.rb | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/terminal-table/table.rb b/lib/terminal-table/table.rb
index f483e31..560f7fa 100644
--- a/lib/terminal-table/table.rb
+++ b/lib/terminal-table/table.rb
@@ -109,6 +109,8 @@ def number_of_columns
     # Set the headings
 
     def headings= arrays
+      return if arrays.nil?
+  
       arrays = [arrays] unless arrays.first.is_a?(Array)
       @headings = arrays.map do |array|
         row = Row.new(self, array)