diff --git a/src/MyPrayerJournal.Api/Data.fs b/src/MyPrayerJournal.Api/Data.fs index 9d2c112..0c50846 100644 --- a/src/MyPrayerJournal.Api/Data.fs +++ b/src/MyPrayerJournal.Api/Data.fs @@ -126,8 +126,8 @@ module Data = .ToListAsync() return jrnl + |> Seq.map (fun r -> r.history <- []; r.notes <- []; r) |> List.ofSeq - |> List.map (fun r -> r.history <- []; r.notes <- []; r) } /// Save changes in the current document session @@ -166,7 +166,9 @@ module Data = .Where(fun x -> x.Id = (RequestId.toString reqId) && x.userId = userId) .ProjectInto() .FirstOrDefaultAsync () - return Option.fromObject req + return + Option.fromObject req + |> Option.map (fun r -> r.history <- []; r.notes <- []; r) } /// Update the recurrence for a request diff --git a/src/MyPrayerJournal.Api/MyPrayerJournal.Api.fsproj b/src/MyPrayerJournal.Api/MyPrayerJournal.Api.fsproj index 3d7a599..8bdd62f 100644 --- a/src/MyPrayerJournal.Api/MyPrayerJournal.Api.fsproj +++ b/src/MyPrayerJournal.Api/MyPrayerJournal.Api.fsproj @@ -14,17 +14,17 @@ - + - - - - + + + + - +