2020-04-18 13:46:28 -05:00
|
|
|
//
|
|
|
|
// TwitterExtendedEntities.swift
|
|
|
|
// Account
|
|
|
|
//
|
|
|
|
// Created by Maurice Parker on 4/18/20.
|
|
|
|
// Copyright © 2020 Ranchero Software, LLC. All rights reserved.
|
|
|
|
//
|
|
|
|
|
|
|
|
import Foundation
|
|
|
|
|
|
|
|
struct TwitterExtendedEntities: Codable {
|
|
|
|
|
2020-04-20 12:05:57 -05:00
|
|
|
let medias: [TwitterExtendedMedia]?
|
2020-04-18 13:46:28 -05:00
|
|
|
|
|
|
|
enum CodingKeys: String, CodingKey {
|
|
|
|
case medias = "media"
|
|
|
|
}
|
|
|
|
|
|
|
|
func renderAsHTML() -> String {
|
|
|
|
var html = String()
|
|
|
|
if let medias = medias {
|
|
|
|
for media in medias {
|
|
|
|
html += media.renderAsHTML()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return html
|
|
|
|
}
|
|
|
|
}
|