Fix issue with legacy handling