Class: Discordrb::Webhooks::EmbedImage

Inherits:
Object
  • Object
show all
Defined in:
lib/discordrb/webhooks/embeds.rb

Overview

An embed's image will be displayed at the bottom, in large format. It will replace a footer icon URL if one is set.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(url: nil) ⇒ EmbedImage

Creates a new image object.


149
150
151
# File 'lib/discordrb/webhooks/embeds.rb', line 149

def initialize(url: nil)
  @url = url
end

Instance Attribute Details

#urlString?


145
146
147
# File 'lib/discordrb/webhooks/embeds.rb', line 145

def url
  @url
end

Instance Method Details

#to_hashHash


154
155
156
157
158
# File 'lib/discordrb/webhooks/embeds.rb', line 154

def to_hash
  {
    url: @url
  }
end