Do not create a new ArrayList every time the items are accessed
This commit is contained in:
parent
baa4b81e77
commit
fe59177efb
@ -14,8 +14,6 @@ class RepositoryImpl(private val api: SelfossApi, private val apiDetails: ApiDet
|
|||||||
val settings = Settings()
|
val settings = Settings()
|
||||||
|
|
||||||
override var items = ArrayList<SelfossModel.Item>()
|
override var items = ArrayList<SelfossModel.Item>()
|
||||||
get() { return ArrayList(field) }
|
|
||||||
set(value) { field = ArrayList(value) }
|
|
||||||
|
|
||||||
override var baseUrl = apiDetails.getBaseUrl()
|
override var baseUrl = apiDetails.getBaseUrl()
|
||||||
override lateinit var dateUtils: DateUtils
|
override lateinit var dateUtils: DateUtils
|
||||||
|
Loading…
Reference in New Issue
Block a user