File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed
templates/cli/app/services Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change 9494 $params[' {{ parameter . name }}' ] = ${{ parameter.name | caseCamel }};
9595{% endfor %}
9696
97+ {% if method.type == ' location ' %}
98+
99+ $params[' project ' ] = $client->getPreference(' X - Appwrite - Project ' );
100+ $params[' key ' ] = $client->getPreference(' X - Appwrite - Key ' );
101+ $path = $client->getPreference(Client::PREFERENCE_ENDPOINT).$path . "?" . http_build_query($params);
102+ echo $path;
103+
104+ {% else %}
105+
97106 $response = $client->call(Client::METHOD_{{ method.method | caseUpper }}, $path, [
98107{% for parameter in method.parameters.header %}
99108 ' {{ parameter . name }}' => ${{ parameter.name | caseCamel }},
@@ -103,12 +112,14 @@ $cli
103112{% endfor %}
104113 ], $params);
105114
115+ $parser->parseResponse($response);
116+
117+ {% endif %}
118+
106119{% if method.packaging %}
107120 unlink($archive_file_path); // as we already obtained a tar.gz
108121 unlink($archive_file_path.' . gz ' );
109122{% endif %}
110-
111- $parser->parseResponse($response);
112123 });
113124
114125{% endfor %}
You can’t perform that action at this time.
0 commit comments