Skip to content

Instantly share code, notes, and snippets.

@westonplatter
Created August 22, 2012 00:19
Show Gist options
  • Save westonplatter/3420744 to your computer and use it in GitHub Desktop.
Save westonplatter/3420744 to your computer and use it in GitHub Desktop.
open_classing
class Tweet
attr_accessor :status
attr_reader :created_at
def initialize(status)
@status = status
@created_at = Time.now
end
end
Tweet.class_eval
def add_smilely_face
status + " - :)"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment