<commit_before>@file:JvmName("Sponsor")

package backend.model.user

import javax.persistence.DiscriminatorValue
import javax.persistence.Entity

@Entity
@DiscriminatorValue("S")
class Sponsor : UserRole {

    var company: String? = null
    var logo: String? = null
    var url: String? = null
    var isHidden: String? = null

    @Embedded
    var address: Address? = null


    /**
     * Private constructor for JPA
     */
    private constructor() : super()

    constructor(core: UserCore) : super(core)

    constructor(core: UserCore, company: String, logo: String, url: String, address: String, isHidden: String) : super(core) {
        this.company = company
        this.logo = logo
        this.url = url<commit_msg>Modify Sponsor to have correct relations<commit_after>@file:JvmName("Sponsor")

package backend.model.user

import backend.model.media.Media
import backend.model.misc.Url
import javax.persistence.CascadeType.ALL
import javax.persistence.DiscriminatorValue
import javax.persistence.Embedded
import javax.persistence.Entity
import javax.persistence.OneToOne

@Entity
@DiscriminatorValue("S")
class Sponsor : UserRole {

    var company: String? = null

    @OneToOne(cascade = arrayOf(ALL), orphanRemoval = true)
    var logo: Media? = null

    @Embedded
    var url: Url? = null

    @Embedded
    var address: Address? = null

    var isHidden: Boolean = false

    /**
     * Private constructor for JPA
     */
    private constructor() : super()

    constructor(core: UserCore) : super(core)

    constructor(core: UserCore, company: String, logo: String, url: Url, address: Address, isHidden: Boolean) : super(core) {
        this.company = company
//        this.logo = logo //TODO: Checkout how to integrate this with media
        this.url = url
{'fraction_non_alphanumeric': 0.1030812324929972, 'fraction_numerical': 0.0, 'mean_word_length': 3.442786069651741, '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': '2263030', 'n_tokens_mistral': 535, 'n_tokens_neox': 520, 'n_words': 151}