In JavaScript it will throw an error unless you explicitly wrap it in
parenthesis, so it's not as applicable here.

(Sent from my phone)
On Jan 14, 2013 9:57 AM, "Garth Webb" <notifications@github.com> wrote:

> In extensions/wikia/WikiaMiniUpload/js/WMU.js:
>
> >  	} else {
> > -		if($G('ImageUploadName')) {
> > -			if( '' == $G( 'ImageUploadName' ).value ) {
> > +		if($('#ImageUploadName').length) {
> > +			if( '' == $( '#ImageUploadName' ).val() ) {
>
> FYI it's standard defensive programming to list the constant first in a
> comparison: 'string' == variable The idea is that if you accidentally just
> type one '=' like this: 'string' = variable you'll get a compile error. If
> you have the variable first: variable = 'string' you'll get an assignment
> with no error and possibly a difficult bug to track down.
> … <#13c3a357bd0fa831_>
> On Fri, Jan 11, 2013 at 3:43 PM, Kyle Florence <notifications@github.com>wrote:
> In extensions/wikia/WikiaMiniUpload/js/WMU.js: > } else { > -
> if($G('ImageUploadName')) { > - if( '' == $G( 'ImageUploadName' ).value ) {
> > + if($('#ImageUploadName').length) { > + if( '' == $( '#ImageUploadName'
> ).val() ) { Yeah. "value is empty" instead of "empty is value" ? Reply to
> this email directly or view it on GitHub<
> https://github.com/Wikia/app/pull/333/files#r2625636>.
>  -- -- Garth Webb Software Engineer * Videogames / Entertainment /
> Lifestyle
> ...................................................................... 500
> 3rd Street, San Francisco, CA 94107 E garth@wikia-inc.com <
> name@wikia-inc.com> C 415-652-7688 WEB WIKIA <http://wikia.com/> |
> FACEBOOK <http://www.facebook.com/wikia> | TWITTER <
> http://twitter.com/wikia> *
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/Wikia/app/pull/333/files#r2638049>.
>
>