fixed bug for tabs