   constructor: (@$container, @settings) ->
     if @settings.selectors[@type]
       @$selector = @$container.find(@settings.selectors[@type])
-      @$selectorGlobal = $(@settings.selectors[@type])
 
-    if @$selector.length and @$selectorGlobal.length
+    if @$selector.length
       @url = @settings.url
       @getCount()
       @initClick()

    super $container, settings, @type

  getCount: ->
    window.ODKL ||= {}
    window.ODKL.updateCount = (idx, number) =>
      @$selectorGlobal.parent().find('span').text number

    $.ajax
      url: "http://ok.ru/dk?st.cmd=extLike&uid=odklcnt0&ref=#{@url}"

  initClick: ->
    @$selector.on 'click', (e) =>
      e.preventDefault()
      title = @settings.title ? encodeURIComponent(document.title)
      open "https://twitter.com/intent/tweet?text=#{title}&url=#{@url}", "_blank", "scrollbars=0, resizable=1, menubar=0, left=100, top=100, width=550, height=440, toolbar=0, status=0"

class App.SocialFb extends App.SocialBase
