From: David ‘Bombe’ Roden Date: Mon, 30 May 2016 16:33:44 +0000 (+0200) Subject: Use shorter getter annotation syntax X-Git-Tag: v2~115 X-Git-Url: https://git.pterodactylus.net/?p=rhynodge.git;a=commitdiff_plain;h=6a35cd098c80b35986ced276a7bc7bd7df8362b9 Use shorter getter annotation syntax --- diff --git a/src/main/kotlin/net/pterodactylus/rhynodge/webpages/weather/WeatherState.kt b/src/main/kotlin/net/pterodactylus/rhynodge/webpages/weather/WeatherState.kt index dff71d7..0d1d7f1 100644 --- a/src/main/kotlin/net/pterodactylus/rhynodge/webpages/weather/WeatherState.kt +++ b/src/main/kotlin/net/pterodactylus/rhynodge/webpages/weather/WeatherState.kt @@ -20,9 +20,8 @@ class WeatherState(val service: String, val dateTime: ZonedDateTime) : AbstractS @JsonProperty("hours") val hours: List = mutableListOf() - val timeMillis: Long - @JsonGetter("dateTime") - get() = dateTime.toInstant().toEpochMilli() + @get:JsonGetter("dateTime") + val timeMillis = dateTime.toInstant().toEpochMilli() operator fun plusAssign(hourState: HourState) { (hours as MutableList).add(hourState)