Fix implicit conversion warnings for getter.