This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def sorted_walk(f): | |
. as $in | |
| if type == "object" then | |
reduce keys[] as $key | |
( {}; . + { ($key): ($in[$key] | sorted_walk(f)) } ) | f | |
elif type == "array" then map( sorted_walk(f) ) | f | |
else f | |
end; | |
def normalize: sorted_walk(if type == "array" then sort else . end); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class UserLikedTracksSearch { | |
private let repository: UserLikesRepository | |
private var results: [PresentableTrackModel] = [] | |
private let coreDataPredicate: NSPredicate | |
init(coreDataPredicate: NSPredicate) { | |
self.coreDataPredicate = coreDataPredicate | |
} |