1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-24 16:52:39 +00:00

eplace another file extension check with a Uniform Type Identifier check

This commit is contained in:
Mitchell Livingston 2009-05-23 20:09:41 +00:00
parent f3398cd608
commit 4eff9949fc

View file

@ -83,7 +83,7 @@
for (NSString * file in files)
{
if ([[file pathExtension] caseInsensitiveCompare: @"torrent"] == NSOrderedSame)
if ([[[NSWorkspace sharedWorkspace] typeOfFile: file error: NULL] isEqualToString: @"org.bittorrent.torrent"])
{
tr_ctor * ctor = tr_ctorNew(fLib);
tr_ctorSetMetainfoFromFile(ctor, [file UTF8String]);