Merge changes I5ef96785,If5df1e55,If30928e1,I667dc8d8,I6896af18, ...
* changes:
Document how to avoid and investigate issues with code owner config files
Fix example in path expressions table
Fix rendering issues in the plugin documentation
Remove unneeded imports
Add helper method to skip tests
Register the BatchModule
Treat uncaught InvalidPathExceptions as '409 Conflict'
diff --git a/ui/code-owners-service.js b/ui/code-owners-service.js
index 8bb14d1..cf9f1f5 100644
--- a/ui/code-owners-service.js
+++ b/ui/code-owners-service.js
@@ -277,7 +277,11 @@
try {
const owners = await this.codeOwnerApi.listOwnersForPath(changeId,
filePath);
- this._fetchedOwners.get(filePath).owners = new Set(owners);
+ // In the upcoming backend changes, the api will return an object instead
+ // of array. While this transition is in progress, the frontend supports
+ // both API - the old one and the new one.
+ this._fetchedOwners.get(filePath).owners = new Set(
+ owners instanceof Array ? owners : owners.code_owners);
} catch (e) {
this._fetchedOwners.get(filePath).error = e;
}