MCPcopy Index your code
hub / github.com/WebODM/WebODM / is_valid

Function is_valid

coreplugins/dronedb/api_views.py:31–33  ·  view source on GitHub ↗
(file)

Source from the content-addressed store, hash-verified

29TAG_PATTERN = re.compile(r'^[a-z0-9][a-z0-9\-]*(/[a-z0-9][a-z0-9\-]*)?$')
30
31def is_valid(file):
32 _, file_extension = path.splitext(file)
33 return file_extension.lower() in VALID_IMAGE_EXTENSIONS or file == 'gcp_list.txt' or file == 'geo.txt'
34
35def get_settings(request):
36 ds = get_current_plugin().get_user_data_store(request.user)

Callers 1

postMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected