Skip to content

Commit

Permalink
feat: add null default arguments for nullable fields
Browse files Browse the repository at this point in the history
  • Loading branch information
wzieba committed Dec 12, 2023
1 parent 93c79ef commit 810dec9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ open class ParselyMetadata
* @param title The title of the content.
* @param publicationDateMilliseconds The date this piece of content was published.
*/(
private val authors: List<String>?,
@JvmField internal val link: String?,
private val section: String?,
private val tags: List<String>?,
private val thumbUrl: String?,
private val title: String?,
private val publicationDateMilliseconds: Long?
private val authors: List<String>? = null,
@JvmField internal val link: String? = null,
private val section: String? = null,
private val tags: List<String>? = null,
private val thumbUrl: String? = null,
private val title: String? = null,
private val publicationDateMilliseconds: Long? = null
) {
/**
* Turn this object into a Map
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ class ParselyVideoMetadata
* @param publicationDateMilliseconds The timestamp in milliseconds this video was published.
* @param durationSeconds Duration of the video in seconds. Required.
*/(
authors: List<String>?,
authors: List<String>? = null,
videoId: String,
section: String?,
tags: List<String>?,
thumbUrl: String?,
title: String?,
publicationDateMilliseconds: Long?,
section: String? = null,
tags: List<String>? = null,
thumbUrl: String? = null,
title: String? = null,
publicationDateMilliseconds: Long? = null,
@JvmField internal val durationSeconds: Int
) : ParselyMetadata(authors, videoId, section, tags, thumbUrl, title, publicationDateMilliseconds) {
/**
Expand Down

0 comments on commit 810dec9

Please sign in to comment.