Skip to content

Commit

Permalink
got rid of loader in data.views
Browse files Browse the repository at this point in the history
  • Loading branch information
XaelShan committed Jul 6, 2023
1 parent 16eb67a commit 1ece72d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions webfit/data/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,8 @@ def data_info(request, db_id, version = None):
return HttpResponseBadRequest("Database ID not public")
file = get_object_or_404(Data, id = db_id)
#TODO ^^ how to check if file_id is in user_file_ids
#TODO doesn't actually load file, fix this (changed file to actual file, not file string) <- possibly get rid of loader, just file
loader = Loader.load(file.file)
return_data = {"info" : loader.__str__()}
#TODO check if this loads the file correctly
return_data = {"info" : file.file.__str__()}
return return_data
return HttpResponseBadRequest()

Expand Down

0 comments on commit 1ece72d

Please sign in to comment.