<commit_before>//
//  Transformer.swift
//  Example
//
//  Created by Limon on 6/24/16.
//  Copyright © 2016 KingfisherExtension. All rights reserved.
//

import UIKit
import KingfisherExtension

enum Style {
    static let square: ImageStyle = .Rectangle(size: CGSize(width: 60.0, height: 60.0))
    static let round1: ImageStyle = .RoundedRectangle(size: CGSize(width: 60.0, height: 60.0), cornerRadius: 8.0, borderWidth: 0)
    static let round2: ImageStyle = .RoundedRectangle(size: CGSize(width: 60.0, height: 60.0), cornerRadius: 16.0, borderWidth: 0)
    static let round3: ImageStyle = .RoundedRectangle(size: CGSize(width: 60.0, height: 60.0), cornerRadius: 60.0 * 0.5, borderWidth: 0)
}

struct Transformer {
    let URLString: String
    let style: ImageStyle
}

extension Transformer: ImageResizable {
    var placeholderImage: UIImage? {

        switch style {
        case .Original, .Rectangle:
            return DefaultImage.pixel
        case .RoundedRectangle:
            return DefaultImage.oval
        }
    }
}

struct DefaultImage {
    static let oval = UIImage(named: "default_avatar_oval")
    static let pixel = UIImage(named: "pixel")!
}<commit_msg>remove force unwrap<commit_after>//
//  Transformer.swift
//  Example
//
//  Created by Limon on 6/24/16.
//  Copyright © 2016 KingfisherExtension. All rights reserved.
//

import UIKit
import KingfisherExtension

enum Style {
    static let square: ImageStyle = .Rectangle(size: CGSize(width: 60.0, height: 60.0))
    static let round1: ImageStyle = .RoundedRectangle(size: CGSize(width: 60.0, height: 60.0), cornerRadius: 8.0, borderWidth: 0)
    static let round2: ImageStyle = .RoundedRectangle(size: CGSize(width: 60.0, height: 60.0), cornerRadius: 16.0, borderWidth: 0)
    static let round3: ImageStyle = .RoundedRectangle(size: CGSize(width: 60.0, height: 60.0), cornerRadius: 60.0 * 0.5, borderWidth: 0)
}

struct Transformer {
    let URLString: String
    let style: ImageStyle
}

extension Transformer: ImageResizable {
    var placeholderImage: UIImage? {

        switch style {
        case .Original, .Rectangle:
            return DefaultImage.pixel
        case .RoundedRectangle:
            return DefaultImage.oval
        }
    }
}

struct DefaultImage {
    static let oval = UIImage(named: "default_avatar_oval")
    static let pixel = UIImage(named: "pixel")
}
{'fraction_non_alphanumeric': 0.11035940803382664, 'fraction_numerical': 0.04143763213530655, 'mean_word_length': 3.2325581395348837, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1763761', 'n_tokens_mistral': 821, 'n_tokens_neox': 741, 'n_words': 216}