djeuscan: fix alive / packaged updates
Signed-off-by: Corentin Chary <corentin.chary@gmail.com>
This commit is contained in:
parent
83f5df4daf
commit
5b1884ead7
@ -207,10 +207,10 @@ class ScanPortage(object):
|
|||||||
overlay=overlay,
|
overlay=overlay,
|
||||||
defaults={"alive": True, "packaged": True}
|
defaults={"alive": True, "packaged": True}
|
||||||
)
|
)
|
||||||
if not created:
|
if not created: # Created objects have defaults values
|
||||||
obj.alive = True
|
obj.alive = True
|
||||||
obj.packaged = True
|
obj.packaged = True
|
||||||
obj.save()
|
obj.save()
|
||||||
|
|
||||||
if created:
|
if created:
|
||||||
self.cache_store_version(obj)
|
self.cache_store_version(obj)
|
||||||
|
@ -57,7 +57,7 @@ class ScanUpstream(object):
|
|||||||
def store_version(self, package, ver, url):
|
def store_version(self, package, ver, url):
|
||||||
obj, created = Version.objects.get_or_create(
|
obj, created = Version.objects.get_or_create(
|
||||||
package=package, slot='', revision='r0', version=ver, overlay='',
|
package=package, slot='', revision='r0', version=ver, overlay='',
|
||||||
defaults={"alive": True, "urls": url, "packaged": True}
|
defaults={"alive": True, "urls": url, "packaged": False}
|
||||||
)
|
)
|
||||||
if not created:
|
if not created:
|
||||||
obj.alive = True
|
obj.alive = True
|
||||||
|
Loading…
Reference in New Issue
Block a user