Fixed js class error