fixed issue where service funciton return type could be a basic type