Fixes broken references