mirror of
https://github.com/OMGeeky/google-apis-rs.git
synced 2026-01-03 01:52:23 +01:00
fix(libdocs): asssure candidate is in mapping
It seems nearly nothing can be taken for granted ;). It's best to just run against a big set of APIs and fix issues as they arise though. More flexibility means more maintenance, after all.
This commit is contained in:
@@ -19,7 +19,7 @@ api:
|
||||
- civicinfo # no oauth2
|
||||
- webmasters # no oauth2
|
||||
- doubleclickbidmanager # no oauth2
|
||||
- freebase # ERROR
|
||||
- freebase # no oauth2
|
||||
- spectrum # no oauth2
|
||||
- qpxexpress # no oauth2
|
||||
- discovery # no oauth2
|
||||
|
||||
@@ -12,7 +12,11 @@
|
||||
# fr == fattest resource, the fatter, the more important, right ?
|
||||
fr = None
|
||||
if schemas:
|
||||
fr = sorted(schemas.values(), key=lambda s: (len(c.sta_map.get(s.id, [])), len(s.get('properties', []))), reverse=True)[0]
|
||||
for candidate in sorted(schemas.values(), key=lambda s: (len(c.sta_map.get(s.id, [])), len(s.get('properties', []))), reverse=True):
|
||||
if candidate.id in c.sta_map:
|
||||
fr = candidate
|
||||
break
|
||||
# end for each candidate to check
|
||||
%>\
|
||||
# Features
|
||||
|
||||
|
||||
Reference in New Issue
Block a user