Sha256: 417d4436288b8231c64ab308238818db7fecb41b9b143760f8f747e124625907
Contents?: true
Size: 420 Bytes
Versions: 16
Compression:
Stored size: 420 Bytes
Contents
module Amakanize module Filters class TrailingParenthesesDeletionFilter < BaseFilter # @note Override # @param string [String] e.g. `"魔法使いの嫁 通常版 4 (BLADE COMICS)"` # @return [String] e.g. `"魔法使いの嫁 通常版 4"` def call(string) string.gsub(/\s*[\((〈《【「『【[\[〔{\{«‹〘〚].*/, "").gsub(/\s*~.+~\z/, "") end end end end
Version data entries
16 entries across 16 versions & 1 rubygems