From 6bc31921a959045c865494fa2fdcfc7f4b04aa6e Mon Sep 17 00:00:00 2001 From: haranicle Date: Thu, 26 May 2016 14:39:07 +0900 Subject: [PATCH] remove codes which is not used --- NohanaImagePicker/AssetCell.swift | 2 +- NohanaImagePicker/AssetDetailListViewController.swift | 3 +-- NohanaImagePicker/AssetListViewController.swift | 3 +-- NohanaImagePicker/MomentViewController.swift | 3 +-- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/NohanaImagePicker/AssetCell.swift b/NohanaImagePicker/AssetCell.swift index 957bd1e..0ed54d9 100644 --- a/NohanaImagePicker/AssetCell.swift +++ b/NohanaImagePicker/AssetCell.swift @@ -29,7 +29,7 @@ class AssetCell: UICollectionViewCell { } @IBAction func didPushPickButton(sender: UIButton) { - guard let asset = asset, nohanaImagePickerController = nohanaImagePickerController else { + guard let asset = asset else { return } if pickButton.selected { diff --git a/NohanaImagePicker/AssetDetailListViewController.swift b/NohanaImagePicker/AssetDetailListViewController.swift index 9cfba15..9d4cc45 100644 --- a/NohanaImagePicker/AssetDetailListViewController.swift +++ b/NohanaImagePicker/AssetDetailListViewController.swift @@ -81,8 +81,7 @@ class AssetDetailListViewController: AssetListViewController { // MARK: - UICollectionViewDelegate override func collectionView(collectionView: UICollectionView, cellForItemAtIndexPath indexPath: NSIndexPath) -> UICollectionViewCell { - guard let cell = collectionView.dequeueReusableCellWithReuseIdentifier("AssetDetailCell", forIndexPath: indexPath) as? AssetDetailCell, - nohanaImagePickerController = nohanaImagePickerController + guard let cell = collectionView.dequeueReusableCellWithReuseIdentifier("AssetDetailCell", forIndexPath: indexPath) as? AssetDetailCell else { fatalError("failed to dequeueReusableCellWithIdentifier(\"AssetDetailCell\")") } diff --git a/NohanaImagePicker/AssetListViewController.swift b/NohanaImagePicker/AssetListViewController.swift index b1370fc..6c39e93 100644 --- a/NohanaImagePicker/AssetListViewController.swift +++ b/NohanaImagePicker/AssetListViewController.swift @@ -83,8 +83,7 @@ class AssetListViewController: UICollectionViewController { } override func collectionView(collectionView: UICollectionView, cellForItemAtIndexPath indexPath: NSIndexPath) -> UICollectionViewCell { - guard let cell = collectionView.dequeueReusableCellWithReuseIdentifier("AssetCell", forIndexPath: indexPath) as? AssetCell, - nohanaImagePickerController = nohanaImagePickerController else { + guard let cell = collectionView.dequeueReusableCellWithReuseIdentifier("AssetCell", forIndexPath: indexPath) as? AssetCell else { fatalError("failed to dequeueReusableCellWithIdentifier(\"AssetCell\")") } cell.tag = indexPath.item diff --git a/NohanaImagePicker/MomentViewController.swift b/NohanaImagePicker/MomentViewController.swift index f46b2c6..c782912 100644 --- a/NohanaImagePicker/MomentViewController.swift +++ b/NohanaImagePicker/MomentViewController.swift @@ -53,8 +53,7 @@ class MomentViewController: AssetListViewController, ActivityIndicatable { // MARK: - UICollectionViewDelegate override func collectionView(collectionView: UICollectionView, cellForItemAtIndexPath indexPath: NSIndexPath) -> UICollectionViewCell { - guard let cell = collectionView.dequeueReusableCellWithReuseIdentifier("AssetCell", forIndexPath: indexPath) as? AssetCell, - nohanaImagePickerController = nohanaImagePickerController else { + guard let cell = collectionView.dequeueReusableCellWithReuseIdentifier("AssetCell", forIndexPath: indexPath) as? AssetCell else { return UICollectionViewCell(frame: CGRectZero) }