如何解决fileAttributesAtPath警告的问题?

Mat*_*der 5 warnings objective-c ios

现在我使用这段代码:

NSDictionary* attr = [[NSFileManager defaultManager] fileAttributesAtPath:file traverseLink:YES];
Run Code Online (Sandbox Code Playgroud)

并得到警告:

'fileAttributesAtPath:traverseLink:' is deprecated
Run Code Online (Sandbox Code Playgroud)

谁知道该用什么呢?

谢谢!

ksh*_*ksh 8

attributesOfItemAtPath:error:改用.