correct handling of badges