Fixes #8704 - Replace jQuery.size() with jQuery.length