bugfix for has method