Avoid missing reference errors

This reverts commit 9f63674bf537a1f37ccdb09c835987aee606b259.