fix bug in referentials
Merge pull request #3321 from ZappoMan/fixReferentialsBug

fix bug in referentials