Skip to content

Commit 99eea9f

Browse files
committed
Bump to v2.1.0 (#2)
* Bump to v2.1.0 - Upgraded Realm to 10.0+ - Upgraded BackgroundRealm to 3.0+ - Upgraded min iOS to 12+, tvOS to 12+ and macOS to 10.12+ * Changed to main branch
1 parent c03140c commit 99eea9f

File tree

19 files changed

+101
-636
lines changed

19 files changed

+101
-636
lines changed

BLResultsController.podspec

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
Pod::Spec.new do |s|
22

33
s.name = "BLResultsController"
4-
s.version = "3.0.0"
4+
s.version = "2.1.0"
55
s.summary = "BLResultsController is not a drop-in replacement for the `NSFetchedResultsController` to be used with Realm."
6-
s.screenshot = "https://github.com/BellAppLab/BLResultsController/raw/master/Images/BLResultsController.png"
6+
s.screenshot = "https://github.com/BellAppLab/BLResultsController/raw/main/Images/BLResultsController.png"
77

88
s.description = <<-DESC
99
Contrary to popular belief, BLResultsController is **not** a drop-in replacement for the `NSFetchedResultsController` to be used with Realm. Oh no. It's _better_.
@@ -38,9 +38,9 @@ Changes to the underlying dataset are calculated on a background queue, therefor
3838

3939
s.swift_version = '5.0', '5.1', '5.2', '5.3'
4040

41-
s.ios.deployment_target = "10.0"
41+
s.ios.deployment_target = "12.0"
4242
s.osx.deployment_target = "10.12"
43-
s.tvos.deployment_target = "11.0"
43+
s.tvos.deployment_target = "12.0"
4444

4545
s.module_name = 'BLResultsController'
4646

@@ -55,7 +55,7 @@ Changes to the underlying dataset are calculated on a background queue, therefor
5555
s.osx.framework = 'AppKit'
5656
s.tvos.framework = 'UIKit'
5757

58-
s.dependency 'RealmSwift', '~> 4.0'
59-
s.dependency 'BackgroundRealm', '~> 2.0'
58+
s.dependency 'RealmSwift', '~> 10.0'
59+
s.dependency 'BackgroundRealm', '~> 3.0'
6060

6161
end

BLResultsController/Core/BLResultsController.swift

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -713,9 +713,15 @@ fileprivate extension ResultsController
713713
realmChangeNotificationToken = nil
714714
reset()
715715

716-
backgroundRealm = BackgroundRealm(configuration: realm.configuration) { [weak self] (realm, error) in
717-
assert(error == nil, "\(className) error: \(error!)")
718-
guard let realm = realm else { return }
716+
backgroundRealm = BackgroundRealm(configuration: realm.configuration) { [weak self] (result) in
717+
guard case let .success(realm) = result else {
718+
if case let .failure(error) = result {
719+
assertionFailure("\(className) error: \(error)")
720+
} else {
721+
assertionFailure("\(className) error. Could not be loaded.")
722+
}
723+
return
724+
}
719725

720726
let results = realm
721727
.objects(Element.self)

CONTRIBUTING.md

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,3 @@
11
# Contributing to BLResultsController
22

3-
## Installation
4-
5-
1. Fork and clone the repo
6-
2. Download Realm into some folder in your machine (it's large and we don't want it in the repo)
7-
- [Earliest supported version](https://static.realm.io/downloads/swift/realm-swift-3.0.0.zip) - v3.0.0
8-
- [Latest supported version](https://static.realm.io/downloads/swift/realm-swift-5.3.3.zip) - v5.3.3
9-
3. Rename the unzipped folder from `realm-swift-<version>` to `realm-swift-latest`
10-
3. Navigate to your clone's folder and create a symbolic link to the Realm libraries
11-
- `ln -s <path/to/realm> ./Realm`
12-
4. Add `Realm.framework` and `RealmSwift.framework` to the **iOS Example**, **tvOS Example** and **macOS Example** targets
13-
5. Clone [BackgroundRealm](https://github.com/BellAppLab/BackgroundRealm) somewhere
14-
- `git clone https://github.com/BellAppLab/BackgroundRealm`
15-
6. Create a symbolic link to `BackgroundRealm`
16-
- `ln -s <path/to/BackgroundRealm> ./BackgroundRealm`
17-
18-
## Changing Versions
19-
20-
* To change the **Xcode** version:
21-
- Go to *Project Navigator* > **Example** > **Example** > **Build Settings** > **XCODE_VERSION**
22-
- _Note 1_: This will automatically change the appropriate Realm version too
3+
TBD

Example/Dummy/dummy.realm.management/access_control.control.mx

Whitespace-only changes.

Example/Dummy/dummy.realm.management/access_control.write.mx

Whitespace-only changes.

Example/Example.xcodeproj/project.pbxproj

Lines changed: 72 additions & 162 deletions
Large diffs are not rendered by default.

Example/Example.xcodeproj/xcshareddata/xcschemes/BLResultsController_iOS.xcscheme

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "1000"
3+
LastUpgradeVersion = "1240"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "YES"
@@ -29,8 +29,6 @@
2929
shouldUseLaunchSchemeArgsEnv = "YES">
3030
<Testables>
3131
</Testables>
32-
<AdditionalOptions>
33-
</AdditionalOptions>
3432
</TestAction>
3533
<LaunchAction
3634
buildConfiguration = "Debug"
@@ -51,8 +49,6 @@
5149
ReferencedContainer = "container:Example.xcodeproj">
5250
</BuildableReference>
5351
</MacroExpansion>
54-
<AdditionalOptions>
55-
</AdditionalOptions>
5652
</LaunchAction>
5753
<ProfileAction
5854
buildConfiguration = "Release"

Example/Example.xcodeproj/xcshareddata/xcschemes/BLResultsController_macOS.xcscheme

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "1000"
3+
LastUpgradeVersion = "1240"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "YES"
@@ -29,8 +29,6 @@
2929
shouldUseLaunchSchemeArgsEnv = "YES">
3030
<Testables>
3131
</Testables>
32-
<AdditionalOptions>
33-
</AdditionalOptions>
3432
</TestAction>
3533
<LaunchAction
3634
buildConfiguration = "Debug"
@@ -51,8 +49,6 @@
5149
ReferencedContainer = "container:Example.xcodeproj">
5250
</BuildableReference>
5351
</MacroExpansion>
54-
<AdditionalOptions>
55-
</AdditionalOptions>
5652
</LaunchAction>
5753
<ProfileAction
5854
buildConfiguration = "Release"

Example/Example.xcodeproj/xcshareddata/xcschemes/BLResultsController_tvOS.xcscheme

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "1000"
3+
LastUpgradeVersion = "1240"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "YES"
@@ -29,8 +29,6 @@
2929
shouldUseLaunchSchemeArgsEnv = "YES">
3030
<Testables>
3131
</Testables>
32-
<AdditionalOptions>
33-
</AdditionalOptions>
3432
</TestAction>
3533
<LaunchAction
3634
buildConfiguration = "Debug"
@@ -51,8 +49,6 @@
5149
ReferencedContainer = "container:Example.xcodeproj">
5250
</BuildableReference>
5351
</MacroExpansion>
54-
<AdditionalOptions>
55-
</AdditionalOptions>
5652
</LaunchAction>
5753
<ProfileAction
5854
buildConfiguration = "Release"

0 commit comments

Comments
 (0)