fix(export): require HTTPS Google endpoint
This commit is contained in:
1 parent
1979583550
commit
af5c047e27
5 files changed
+15
-2
No files matched your search
@@ -6,6 +6,7 @@ import json
|
||||
import os
|
||||
from dataclasses import dataclass
|
||||
from urllib.error import URLError
|
||||
from urllib.parse import urlparse
|
||||
from urllib.request import Request, urlopen
|
||||
|
||||
from .applications import ApplicationStore
|
||||
@@ -29,7 +30,8 @@ class GoogleSheetsExportConfig:
|
||||
|
||||
@property
|
||||
def ready(self) -> bool:
|
||||
return self.enabled and bool(self.url)
|
||||
parsed = urlparse(self.url)
|
||||
return self.enabled and parsed.scheme == "https" and bool(parsed.hostname)
|
||||
|
||||
|
||||
class GoogleSheetsExportService:
|
||||
|
||||
Reference in new issue
Block a user