mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-06-05 03:57:25 +02:00
formatted for linting
This commit is contained in:
parent
5811448450
commit
96714c4eb2
3 changed files with 2 additions and 3 deletions
|
@ -82,7 +82,7 @@ def available(request, domain=""):
|
||||||
Response is a JSON dictionary with the key "available" and value true or
|
Response is a JSON dictionary with the key "available" and value true or
|
||||||
false.
|
false.
|
||||||
"""
|
"""
|
||||||
domain = request.GET.get('domain', '')
|
domain = request.GET.get("domain", "")
|
||||||
DraftDomain = apps.get_model("registrar.DraftDomain")
|
DraftDomain = apps.get_model("registrar.DraftDomain")
|
||||||
# validate that the given domain could be a domain name and fail early if
|
# validate that the given domain could be a domain name and fail early if
|
||||||
# not.
|
# not.
|
||||||
|
|
|
@ -73,7 +73,6 @@ function debounce(handler, cooldown=600) {
|
||||||
|
|
||||||
/** Asyncronously fetches JSON. No error handling. */
|
/** Asyncronously fetches JSON. No error handling. */
|
||||||
function fetchJSON(endpoint, callback, url="/api/v1/") {
|
function fetchJSON(endpoint, callback, url="/api/v1/") {
|
||||||
console.log("fetchJSON called for endpoint " + endpoint);
|
|
||||||
const xhr = new XMLHttpRequest();
|
const xhr = new XMLHttpRequest();
|
||||||
xhr.open('GET', url + endpoint);
|
xhr.open('GET', url + endpoint);
|
||||||
xhr.send();
|
xhr.send();
|
||||||
|
|
|
@ -91,7 +91,7 @@ class TestFormValidation(MockEppLib):
|
||||||
form.errors["requested_domain"],
|
form.errors["requested_domain"],
|
||||||
["Enter the .gov domain you want without any periods."],
|
["Enter the .gov domain you want without any periods."],
|
||||||
)
|
)
|
||||||
|
|
||||||
def test_requested_domain_invalid_characters(self):
|
def test_requested_domain_invalid_characters(self):
|
||||||
"""must be a valid .gov domain name."""
|
"""must be a valid .gov domain name."""
|
||||||
form = DotGovDomainForm(data={"requested_domain": "underscores_forever"})
|
form = DotGovDomainForm(data={"requested_domain": "underscores_forever"})
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue