Open robmarkcole opened 4 years ago
Use if flask.request.method != "POST" or not flask.request.files.get("image"):, do the negative. This saves indentation. Same for if not predictions
if flask.request.method != "POST" or not flask.request.files.get("image"):
if not predictions
https://refactoring.com/catalog/replaceNestedConditionalWithGuardClauses.html
Use
if flask.request.method != "POST" or not flask.request.files.get("image"):
, do the negative. This saves indentation. Same forif not predictions
https://refactoring.com/catalog/replaceNestedConditionalWithGuardClauses.html