From 3af24ac8614be2f29e00a1ff497f2c50bcc60b49 Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Wed, 4 Dec 2024 13:40:12 -0500 Subject: [PATCH] rubocop --- lib/lightspeed_restaurant/operations/renew.rb | 2 +- spec/lightspeed_restaurant/webhook_spec.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/lightspeed_restaurant/operations/renew.rb b/lib/lightspeed_restaurant/operations/renew.rb index 1104957..4d807c4 100644 --- a/lib/lightspeed_restaurant/operations/renew.rb +++ b/lib/lightspeed_restaurant/operations/renew.rb @@ -4,7 +4,7 @@ module LightspeedRestaurantClient module Operations module Renew def renew(id, configuration = nil) - response = JSON.parse(LightspeedRestaurantClient.post(default_resource_path + "/#{id}" + "/renew", {}, configuration)) + response = JSON.parse(LightspeedRestaurantClient.post("#{default_resource_path}/#{id}/renew", {}, configuration)) new(response) end end diff --git a/spec/lightspeed_restaurant/webhook_spec.rb b/spec/lightspeed_restaurant/webhook_spec.rb index 68e1f50..573f680 100644 --- a/spec/lightspeed_restaurant/webhook_spec.rb +++ b/spec/lightspeed_restaurant/webhook_spec.rb @@ -23,13 +23,13 @@ module LightspeedRestaurantClient it 'includes the notification URL' do result = described_class.find(resource_id) - expect(result.notificationUrl).to eq "https://localhost" + expect(result.notificationUrl).to eq 'https://localhost' end end end context 'when creating' do - let(:valid_params) { { notificationUrl: 'https://localhost', type: "RECEIPT_CREATED", timeToLiveInSeconds: 900} } + let(:valid_params) { { notificationUrl: 'https://localhost', type: 'RECEIPT_CREATED', timeToLiveInSeconds: 900 } } let(:invalid_params) { { notificationUrl: '' } } context 'with invalid params' do