mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-05-22 23:52:11 +02:00
Merge pull request #7206 from vector-im/alfogrillo/poll_decryption_message
Handle decryption errors in polls (PSG-1023)
This commit is contained in:
@@ -2349,6 +2349,8 @@ Tap the + to start adding people.";
|
||||
|
||||
"poll_timeline_not_closed_subtitle" = "Please try again";
|
||||
|
||||
"poll_timeline_decryption_error" = "Due to decryption errors, some votes may not be counted";
|
||||
|
||||
// MARK: - Location sharing
|
||||
|
||||
"location_sharing_title" = "Location";
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
//
|
||||
// Copyright 2022 New Vector Ltd
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
extension Sequence {
|
||||
func group<GroupID: Hashable>(by keyPath: KeyPath<Element, GroupID>) -> [GroupID: [Element]] {
|
||||
var result: [GroupID: [Element]] = .init()
|
||||
|
||||
for item in self {
|
||||
let groupId = item[keyPath: keyPath]
|
||||
result[groupId] = (result[groupId] ?? []) + [item]
|
||||
}
|
||||
|
||||
return result
|
||||
}
|
||||
}
|
||||
@@ -4839,6 +4839,10 @@ public class VectorL10n: NSObject {
|
||||
public static var pollEditFormUpdateFailureTitle: String {
|
||||
return VectorL10n.tr("Vector", "poll_edit_form_update_failure_title")
|
||||
}
|
||||
/// Due to decryption errors, some votes may not be counted
|
||||
public static var pollTimelineDecryptionError: String {
|
||||
return VectorL10n.tr("Vector", "poll_timeline_decryption_error")
|
||||
}
|
||||
/// Please try again
|
||||
public static var pollTimelineNotClosedSubtitle: String {
|
||||
return VectorL10n.tr("Vector", "poll_timeline_not_closed_subtitle")
|
||||
|
||||
Reference in New Issue
Block a user