File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed
Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change 5555@homepage http://polymerlabs.github.io/google-apis
5656-->
5757< polymer-element name ="google-api-loader "
58- attributes ="name version root "
58+ attributes ="name version appId "
5959 extends ="google-client-api "
6060 on-api-load ="{{doneLoadingClient}} ">
6161< script >
103103 version : '' ,
104104
105105 /**
106- * Root URL for loading a Google Cloud Endpoints API.
107- * A valid root URL looks like this:
108- * 'https://your_app_id.appspot.com/_ah/api'
109- * @attribute root
106+ * App Engine application ID for loading a Google Cloud Endpoints API.
107+ * @attribute appId
110108 * @type string
111109 */
112110
195193 this . fireError ( ) ;
196194 // Otherwise, looks like we're loading a new API.
197195 } else {
196+ var root ;
197+ if ( this . appId ) {
198+ root = 'https://' + this . appId + '.appspot.com/_ah/api' ;
199+ }
198200 statuses_ [ this . name ] = 'loading' ;
199201 loaders_ [ this . name ] = this ;
200202 gapi . client . load ( this . name , this . version ,
201- this . handleLoadResponse . bind ( this ) , this . root ) ;
203+ this . handleLoadResponse . bind ( this ) , root ) ;
202204 }
203205 }
204206 }
You can’t perform that action at this time.
0 commit comments