Because, according to the docs, it returns the empty string when  
there is no extension.

Christiaan

On 15 May 2007, at 5:33 PM, Adam R. Maxwell wrote:

> Why check -length on the return value from a dictionary?  Won't it  
> just be nil?  I know that [nil length] == 0, but I have this deeply  
> ingrained resistance to ever checking -[NSString length] :).
>
> NSString *bundleID = [defaultViewers objectForKey:extension];
>   if ([bundleID length])



-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Bibdesk-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-develop

Reply via email to