Only notify once on update. fix #515
This commit is contained in:
@@ -20,6 +20,8 @@ log = CPLog(__name__)
|
||||
|
||||
class Updater(Plugin):
|
||||
|
||||
available_notified = False
|
||||
|
||||
def __init__(self):
|
||||
|
||||
if Env.get('desktop'):
|
||||
@@ -69,8 +71,9 @@ class Updater(Plugin):
|
||||
return
|
||||
|
||||
if self.updater.check():
|
||||
if self.conf('notification') and not self.conf('automatic'):
|
||||
if not self.available_notified and self.conf('notification') and not self.conf('automatic'):
|
||||
fireEvent('updater.available', message = 'A new update is available', data = self.updater.info())
|
||||
self.available_notified = True
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
Reference in New Issue
Block a user