From 2b7ea39b037e56da36f8dcf02c93a9ed88ca4873 Mon Sep 17 00:00:00 2001 From: Ryan Hammett Date: Mon, 1 Feb 2016 15:53:36 -0500 Subject: [PATCH] Breaking things, bad at regex --- slack-pixiv/commands/pixiv.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slack-pixiv/commands/pixiv.rb b/slack-pixiv/commands/pixiv.rb index b71c5e3..7c7f565 100644 --- a/slack-pixiv/commands/pixiv.rb +++ b/slack-pixiv/commands/pixiv.rb @@ -13,7 +13,7 @@ module SlackMathbot # Create iOS Illustration URL # ios_url = "pixiv://illusts/" + pixiv_url.split("illust_id=")[-1] - ios_url = "pixiv://illusts/" + pixiv_url.to_s.slice(/^[0-9]+$/) + ios_url = "pixiv://illusts/" + pixiv_url.slice(/(^[0-9]+$)/) puts ios_url