Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 11 additions & 9 deletions src/Backends/SystemUpdate.vala
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,19 @@ public class SettingsDaemon.Backends.SystemUpdate : Object {

cancellable = new GLib.Cancellable ();

try {
var last_offline_results = Pk.offline_get_results ();
GLib.Application.get_default ().startup.connect (() => {
try {
var last_offline_results = Pk.offline_get_results ();

if (last_offline_results.get_exit_code () != SUCCESS && last_offline_results.get_error_code () != null) {
send_error (last_offline_results.get_error_code ().details);
} else {
GLib.Application.get_default ().withdraw_notification (NOTIFICATION_ID);
if (last_offline_results.get_exit_code () != SUCCESS && last_offline_results.get_error_code () != null) {
send_error (last_offline_results.get_error_code ().details);
} else {
GLib.Application.get_default ().withdraw_notification (NOTIFICATION_ID);
}
} catch (Error e) {
warning ("Couldn't determine last offline results: %s", e.message);
}
} catch (Error e) {
warning ("Couldn't determine last offline results: %s", e.message);
}
});

try {
prepared_update_monitor = Pk.offline_get_prepared_monitor ();
Expand Down
Loading