From ca7a8a68ef25f12fd575c5b94c0dc22025ff3be2 Mon Sep 17 00:00:00 2001 From: Ali Naqvi Date: Mon, 2 Dec 2024 19:11:02 +0800 Subject: [PATCH] refactor: code refactoring --- src/controllers/calendars.cr | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/controllers/calendars.cr b/src/controllers/calendars.cr index 87ab9ea..d4227dc 100644 --- a/src/controllers/calendars.cr +++ b/src/controllers/calendars.cr @@ -11,7 +11,7 @@ class Calendars < Application @[AC::Route::Filter(:before_action)] private def ensure_tenant - raise Error::NotImplemented.new("domain does not have a tenant configured") unless current_tenant + current_tenant end @[AC::Route::Filter(:before_action, except: [:index])] @@ -67,9 +67,6 @@ class Calendars < Application calendars = all_calendars.to_a render :no_content, json: [] of Availability if calendars.empty? - - # raise Error::TenantNotFound.new("no tenants exist") if calendars.empty? - # perform availability request period_start = Time.unix(period_start) period_end = Time.unix(period_end)