fixing addClass mehtod