From cd86a25cb7a40ed8c77cea85b964a670a75a9255 Mon Sep 17 00:00:00 2001 From: Masayuki Ono Date: Wed, 3 May 2017 16:00:21 +0900 Subject: [PATCH] =?UTF-8?q?Check=20=E2=80=98Pods/Target=20Support=20Files?= =?UTF-8?q?=E2=80=99=20existence?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Sources/LicensePlistCore/LicensePlist.swift | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Sources/LicensePlistCore/LicensePlist.swift b/Sources/LicensePlistCore/LicensePlist.swift index 12e905f2..78f8106a 100644 --- a/Sources/LicensePlistCore/LicensePlist.swift +++ b/Sources/LicensePlistCore/LicensePlist.swift @@ -108,6 +108,10 @@ public final class LicensePlist { } let path = (path ?? URL(fileURLWithPath: podsDirectoryName)).appendingPathComponent("Target Support Files") let fm = FileManager.default + if !fm.fileExists(atPath: path.path) { + Log.warning("not found: \(path)") + return [] + } let urls = (try! fm.contentsOfDirectory(at: path, includingPropertiesForKeys: nil, options: [])) .filter { var isDirectory: ObjCBool = false