Sha256: ff45e2658b8389d994bfed4ec4577063b20e1517a9a7611a1a08520852b27193

Contents?: true

Size: 402 Bytes

Versions: 1

Compression:

Stored size: 402 Bytes

Contents

%w{
murlsh
}.each { |m| require m }

module Murlsh

  # show the time the url was posted
  class UrlDisplayAdd65Time < Plugin

    @hook = 'url_display_add'

    # show the time the url was posted
    def self.run(markup, url, config)
      if url.time
        display_time = url.time.extend(Murlsh::TimeAgo).ago
        markup.span(", #{display_time}", :class => 'date')
      end
    end

  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
murlsh-1.0.0 plugins/url_display_add_65_time.rb