something wrong with func def