Class: IdsPlease::Parsers::Twitter

Inherits:
Base
  • Object
show all
Defined in:
lib/ids_please/parsers/twitter.rb

Constant Summary collapse

MASK =
/twitter/i

Class Method Summary collapse

Methods inherited from Base

interact, to_sym, valid_id_regex

Class Method Details



8
9
10
11
12
13
14
15
# File 'lib/ids_please/parsers/twitter.rb', line 8

def parse_link(link)
  if link.path =~ /%23!/
    id = link.path.sub(/\A\/%23!\//, '')
    id.split(/[\/\?#]/).first
  else
    super
  end
end