add missing return statement in get_data