Change `typeof YUI` check to simply see if `YUI` is defined