Code cleanup
This commit is contained in:
parent
16bc3f81b9
commit
9a417c41be
|
|
@ -80,18 +80,21 @@ class WebClient {
|
||||||
if (multipartFiles != null) {
|
if (multipartFiles != null) {
|
||||||
response = await _uploadFiles(url, token, multipartFiles, data: data);
|
response = await _uploadFiles(url, token, multipartFiles, data: data);
|
||||||
} else {
|
} else {
|
||||||
|
final headers = _getHeaders(
|
||||||
|
url,
|
||||||
|
token,
|
||||||
|
secret: secret,
|
||||||
|
password: password,
|
||||||
|
idToken: idToken,
|
||||||
|
);
|
||||||
|
//print('Headers: $headers');
|
||||||
|
|
||||||
final client = http.Client();
|
final client = http.Client();
|
||||||
response = await client
|
response = await client
|
||||||
.post(
|
.post(
|
||||||
Uri.parse(url),
|
Uri.parse(url),
|
||||||
body: data,
|
body: data,
|
||||||
headers: _getHeaders(
|
headers: headers,
|
||||||
url,
|
|
||||||
token,
|
|
||||||
secret: secret,
|
|
||||||
password: password,
|
|
||||||
idToken: idToken,
|
|
||||||
),
|
|
||||||
)
|
)
|
||||||
.timeout(
|
.timeout(
|
||||||
Duration(
|
Duration(
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue