mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-09 14:56:10 +01:00
bug fix: soa parsing ref https://github.com/usmannasir/cyberpanel/issues/1341
This commit is contained in:
@@ -680,11 +680,16 @@ class DNS:
|
|||||||
return
|
return
|
||||||
|
|
||||||
if zone.type == 'MASTER':
|
if zone.type == 'MASTER':
|
||||||
getSOA = Records.objects.get(domainOwner=zone, type='SOA')
|
try:
|
||||||
|
for getSOA in Records.objects.filter(domainOwner=zone, type='SOA'):
|
||||||
|
#getSOA = Records.objects.get(domainOwner=zone, type='SOA')
|
||||||
soaContent = getSOA.content.split(' ')
|
soaContent = getSOA.content.split(' ')
|
||||||
soaContent[2] = str(int(soaContent[2]) + 1)
|
soaContent[2] = str(int(soaContent[2]) + 1)
|
||||||
getSOA.content = " ".join(soaContent)
|
getSOA.content = " ".join(soaContent)
|
||||||
getSOA.save()
|
getSOA.save()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
if type == 'NS':
|
if type == 'NS':
|
||||||
if Records.objects.filter(name=name, type=type, content=value).count() == 0:
|
if Records.objects.filter(name=name, type=type, content=value).count() == 0:
|
||||||
|
|||||||
Reference in New Issue
Block a user