Find remote installation type in a better way

Make it so that the options in the remote Options column are looped through to find user or system, instead of always assuming is the first option
This commit is contained in:
heliguy
2023-09-24 02:59:51 -04:00
parent 10bebafdd5
commit 9ffa3d6cba
2 changed files with 11 additions and 3 deletions

View File

@@ -85,9 +85,17 @@ class myUtils:
data.append(row) data.append(row)
try: try:
for i in range(len(data)): for i in range(len(data)):
data[i][7] = data[i][7].split(",")[0] data[i][7] = data[i][7].split(",")
for j in range(len(data[i])):
if data[i][7][j] == "user":
data[i][7] = "user"
break
if data[i][7][j] == "system":
data[i][7] = "system"
break
except: except:
pass print("error getting remote installation types")
return data return data
def getHostFlatpaks(self): def getHostFlatpaks(self):

View File

@@ -75,7 +75,7 @@ template WarehouseWindow : Adw.ApplicationWindow {
Adw.StatusPage no_flatpaks { Adw.StatusPage no_flatpaks {
icon-name: "error-symbolic"; icon-name: "error-symbolic";
title: _("No Flatpaks Found"); title: _("No Flatpaks Found");
description: _("Warehouse cannot see the list of installed Flatpaks or the system has no Flatpaks installed."); description: _("There are either no Flatpaks that match the current filter, Warehouse cannot see the list of installed Flatpaks, or the system has no Flatpaks installed.");
} }
} }
}; };