From 703ad99bf8de24137a8d635c13d6c7c8bc6b1f56 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Sun, 31 Dec 2023 17:40:32 +0900 Subject: [PATCH] [ruby/win32ole] Use `end_with?` and fix indent https://github.com/ruby/win32ole/commit/7648ee7e56 --- ext/win32ole/sample/olegen.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/win32ole/sample/olegen.rb b/ext/win32ole/sample/olegen.rb index 4b088a774f..9398194cf1 100644 --- a/ext/win32ole/sample/olegen.rb +++ b/ext/win32ole/sample/olegen.rb @@ -70,8 +70,8 @@ class WIN32COMGen end if ts.empty? ts = 'VT_VARIANT' - elsif ts[-1] == ?| - ts += 'VT_VARIANT' + elsif ts.end_with?(?|) + ts += 'VT_VARIANT' end ts end