fix missed cases for non-jQuery