MCPcopy Create free account
hub / github.com/hunvreus/devpush / validate_confirm

Method validate_confirm

app/forms/project.py:372–384  ·  view source on GitHub ↗
(self, field)

Source from the content-addressed store, hash-verified

370 raise ValidationError(_("Domain not found."))
371
372 def validate_confirm(self, field):
373 domain = next(
374 (
375 domain
376 for domain in self.domains
377 if domain.id == int(self.domain_id.data)
378 ),
379 None,
380 )
381 if not domain:
382 raise ValidationError(_("Domain not found."))
383 if field.data != domain.hostname:
384 raise ValidationError(_("Domain confirmation did not match."))
385
386
387class ProjectDomainVerifyForm(StarletteForm):

Callers

nothing calls this directly

Calls 2

nextFunction · 0.85
_Function · 0.50

Tested by

no test coverage detected