Flask doesn't like my `return` statements