Browse Source

Merge pull request #1086 from nextcloud/performance/nextcloud/change_spread_operator

perf(nextcloud): do not use the spread operator for building lists
pull/1092/head
Nikolas Rimikis 1 year ago committed by GitHub
parent
commit
c127a34c44
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      packages/nextcloud/lib/src/client.dart

6
packages/nextcloud/lib/src/client.dart

@ -35,18 +35,16 @@ class NextcloudClient extends DynamiteClient {
baseHeaders: language != null ? {'Accept-Language': language} : null,
userAgent: userAgentOverride ?? appType.userAgent,
authentications: [
if (appPassword != null) ...[
if (appPassword != null)
DynamiteHttpBearerAuthentication(
token: appPassword,
),
],
if (loginName != null && (password ?? appPassword) != null) ...[
if (loginName != null && (password ?? appPassword) != null)
DynamiteHttpBasicAuthentication(
username: loginName,
password: (password ?? appPassword)!,
),
],
],
);
/// Identifier used for authentication. This can be the username or email or something else.

Loading…
Cancel
Save