refactored side bar code