-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify BluetoothAttributeInstanceMap::GetOrCreate*
GetOrCreateRemoteGATTService, GetOrCreateRemoteGATTCharacteristic and GetOrCreateBluetoothRemoteGATTDescriptor use a similar pattern where they lookup an object by id, and if no object exists it is created. This pattern uses at() followed by an (optional) insert() - this can be written as a single insert() which reduces boilerplate. Change-Id: Ic46c0fe0c3adea404f8844bda147bd89ebf4df75 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2289854 Reviewed-by: Reilly Grant <reillyg@chromium.org> Commit-Queue: Fredrik Söderquist <fs@opera.com> Cr-Commit-Position: refs/heads/master@{#788985}
- Loading branch information
Fredrik Söderqvist
authored and
Commit Bot
committed
Jul 16, 2020
1 parent
ab7cc5c
commit ef20f11
Showing
1 changed file
with
16 additions
and
24 deletions.
There are no files selected for viewing
This file contains 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