[jQuery] $this.filter('.myclass').myplugin() OR $this.is('.myclass') && $this.myplugin()

[jQuery] $this.filter('.myclass').myplugin() OR $this.is('.myclass') && $this.myplugin()

I have a curiosity question,
Imagine I want to apply a function (myplugin()) to a jquery object if
this has a particular className.
Imagine that NO jquery object has 'myclass' associated and myplugin()
NOT exist.
so
$this.filter('.myclass').length == 0
and
$this.is('.myclass') == false
1. most common possibility: throws an error (myplugin doesn't exist: It
tries to bind an inexistent function to ZERO)
$this.filter('.myclass').myplugin()
2. alternative possibility: no error (does nothing)
$this.is('.myclass') && $this.myplugin()
Now imagine that myplugin() EXISTS (and you have lot of lines of this
kind: different filters and methods)
My question: which possibility (1 or 2) is the best in the meaning of
time speed and overheads?
thanxs
--
Enrique Meléndez Estrada (976 01 0083)
Dpto. Servicios Informáticos
Área Organización y Servicios Internos
INSTITUTO TECNOLÓGICO DE ARAGÓN
c/ María de Luna 8, 50018, Zaragoza (Spain)
emelendez@ita.es - http://www.ita.es