refactor myflaskr