wip
This commit is contained in:
17
Shared/Stats.swift
Normal file
17
Shared/Stats.swift
Normal file
@@ -0,0 +1,17 @@
|
||||
//
|
||||
// Stats.swift
|
||||
// Feels
|
||||
//
|
||||
// Created by Trey Tartt on 1/14/22.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
|
||||
class Stats {
|
||||
static func getCountFor(moodType: Mood, inData data: [MoodEntry]) -> Int {
|
||||
let num = data.filter({
|
||||
$0.moodValue == moodType.rawValue
|
||||
}).count
|
||||
return num
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user