cleanup navbar logic