Sha256: 8584e238524536fa974956474be4ce6dc18ab27fdaad38170cfa3fb197fc44c3
Contents?: true
Size: 320 Bytes
Versions: 4
Compression:
Stored size: 320 Bytes
Contents
module MongoidShortener module ShortenedUrlsHelper # generate a url from either a url string, or a shortened url object def shortened_url(url) raise "Only String accepted: #{url}" unless url.class == String short_url = MongoidShortener::ShortenedUrl.generate(url) short_url end end end
Version data entries
4 entries across 4 versions & 1 rubygems