fix badly coded sidebar