Fixed an issue with reference_once