Fix BDS bug