File tree 1 file changed +9
-1
lines changed
1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -721,6 +721,14 @@ def get_admin(cfg: dict) -> dict:
721
721
res_eg = {
722
722
res_eg_key : cfg ['resources' ][res_eg_key ]
723
723
}
724
+ if 'extents' in res_eg [res_eg_key ]:
725
+ res_eg_eg_key = 'extents'
726
+ elif 'type' in res_eg [res_eg_key ]:
727
+ res_eg_eg_key = 'type'
728
+
729
+ res_eg [res_eg_key ]['patch_example' ] = {
730
+ res_eg_eg_key : res_eg [res_eg_key ][res_eg_eg_key ]
731
+ }
724
732
725
733
paths ['/admin/config' ] = {
726
734
'get' : {
@@ -887,7 +895,7 @@ def get_admin(cfg: dict) -> dict:
887
895
'description' : 'Updates admin configuration resource' ,
888
896
'content' : {
889
897
'application/json' : {
890
- 'example' : { 'extents' : res_eg [res_eg_key ]['extents' ]} ,
898
+ 'example' : res_eg [res_eg_key ]['patch_example' ] ,
891
899
'schema' : schema_dict ['properties' ]['resources' ]['patternProperties' ]['^.*$' ] # noqa
892
900
}
893
901
},
You can’t perform that action at this time.
0 commit comments