updated return data type to deal with scrutinizer warning