From 7e5d1bfd25623a6f3063de5699dca62cd33f08ce Mon Sep 17 00:00:00 2001 From: Jonas Lochmann Date: Mon, 8 Feb 2021 01:00:00 +0100 Subject: [PATCH] Sort devices by id --- app/src/main/java/io/timelimit/android/data/dao/DeviceDao.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/io/timelimit/android/data/dao/DeviceDao.kt b/app/src/main/java/io/timelimit/android/data/dao/DeviceDao.kt index 961f220..88d0551 100644 --- a/app/src/main/java/io/timelimit/android/data/dao/DeviceDao.kt +++ b/app/src/main/java/io/timelimit/android/data/dao/DeviceDao.kt @@ -1,5 +1,5 @@ /* - * TimeLimit Copyright 2019 - 2020 Jonas Lochmann + * TimeLimit Copyright 2019 - 2021 Jonas Lochmann * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -38,7 +38,7 @@ abstract class DeviceDao { @Query("SELECT * FROM device WHERE id = :deviceId") abstract fun getDeviceByIdSync(deviceId: String): Device? - @Query("SELECT * FROM device") + @Query("SELECT * FROM device ORDER BY id") abstract fun getAllDevicesLive(): LiveData> @Query("SELECT * FROM device")