diff options
Diffstat (limited to 'Firestore/Example/Tests/Util/FSTHelpers.mm')
-rw-r--r-- | Firestore/Example/Tests/Util/FSTHelpers.mm | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/Firestore/Example/Tests/Util/FSTHelpers.mm b/Firestore/Example/Tests/Util/FSTHelpers.mm index 586fdbc..649486a 100644 --- a/Firestore/Example/Tests/Util/FSTHelpers.mm +++ b/Firestore/Example/Tests/Util/FSTHelpers.mm @@ -107,7 +107,7 @@ FSTFieldPath *FSTTestFieldPath(NSString *field) { FSTFieldValue *FSTTestFieldValue(id _Nullable value) { // This owns the DatabaseIds since we do not have FirestoreClient instance to own them. - static DatabaseId database_id{"project", DatabaseId::kDefaultDatabaseId}; + static DatabaseId database_id{"project", DatabaseId::kDefault}; FSTUserDataConverter *converter = [[FSTUserDataConverter alloc] initWithDatabaseID:&database_id preConverter:^id _Nullable(id _Nullable input) { @@ -172,10 +172,12 @@ FSTResourcePath *FSTTestPath(NSString *path) { return [FSTResourcePath pathWithSegments:FSTTestSplitPath(path)]; } -FSTDocumentKeyReference *FSTTestRef(NSString *projectID, NSString *database, NSString *path) { +FSTDocumentKeyReference *FSTTestRef(const absl::string_view projectID, + const absl::string_view database, + NSString *path) { // This owns the DatabaseIds since we do not have FirestoreClient instance to own them. static std::list<DatabaseId> database_ids; - database_ids.emplace_back(util::MakeStringView(projectID), util::MakeStringView(database)); + database_ids.emplace_back(projectID, database); return [[FSTDocumentKeyReference alloc] initWithKey:FSTTestDocKey(path) databaseID:&database_ids.back()]; } |