summaryrefslogtreecommitdiffstats
path: root/apps/files_external/lib
diff options
context:
space:
mode:
authorRobin McCorkell <rmccorkell@owncloud.com>2015-09-17 17:01:55 +0100
committerThomas Müller <thomas.mueller@tmit.eu>2015-09-23 12:10:02 +0200
commit634c1c497c51f00ba5512dae69dfffaf6cf0e3e1 (patch)
tree27f1ded985e450b7d3056b12349df434cfe6d507 /apps/files_external/lib
parent2bef3ef34bc81737c1667187aa3b21ecf1442e03 (diff)
downloadnextcloud-server-634c1c497c51f00ba5512dae69dfffaf6cf0e3e1.tar.gz
nextcloud-server-634c1c497c51f00ba5512dae69dfffaf6cf0e3e1.zip
Mark SMB_OC and SFTP_Key as deprecated backends
Diffstat (limited to 'apps/files_external/lib')
-rw-r--r--apps/files_external/lib/backend/sftp_key.php6
-rw-r--r--apps/files_external/lib/backend/smb_oc.php6
2 files changed, 8 insertions, 4 deletions
diff --git a/apps/files_external/lib/backend/sftp_key.php b/apps/files_external/lib/backend/sftp_key.php
index 4a7f565eb19..13f45f1140c 100644
--- a/apps/files_external/lib/backend/sftp_key.php
+++ b/apps/files_external/lib/backend/sftp_key.php
@@ -27,14 +27,15 @@ use \OCA\Files_External\Lib\DefinitionParameter;
use \OCA\Files_External\Lib\Auth\AuthMechanism;
use \OCA\Files_External\Service\BackendService;
use \OCA\Files_External\Lib\Auth\PublicKey\RSA;
+use \OCA\Files_External\Lib\Backend\SFTP;
class SFTP_Key extends Backend {
- public function __construct(IL10N $l, RSA $legacyAuth) {
+ public function __construct(IL10N $l, RSA $legacyAuth, SFTP $sftpBackend) {
$this
->setIdentifier('\OC\Files\Storage\SFTP_Key')
->setStorageClass('\OC\Files\Storage\SFTP')
- ->setText($l->t('SFTP with secret key login [DEPRECATED]'))
+ ->setText($l->t('SFTP with secret key login'))
->addParameters([
(new DefinitionParameter('host', $l->t('Host'))),
(new DefinitionParameter('root', $l->t('Remote subfolder')))
@@ -42,6 +43,7 @@ class SFTP_Key extends Backend {
])
->addAuthScheme(AuthMechanism::SCHEME_PUBLICKEY)
->setLegacyAuthMechanism($legacyAuth)
+ ->deprecateTo($sftpBackend)
;
}
diff --git a/apps/files_external/lib/backend/smb_oc.php b/apps/files_external/lib/backend/smb_oc.php
index a3f3a824040..9fc17400884 100644
--- a/apps/files_external/lib/backend/smb_oc.php
+++ b/apps/files_external/lib/backend/smb_oc.php
@@ -29,6 +29,7 @@ use \OCA\Files_External\Service\BackendService;
use \OCA\Files_External\Lib\Auth\Password\SessionCredentials;
use \OCA\Files_External\Lib\StorageConfig;
use \OCA\Files_External\Lib\LegacyDependencyCheckPolyfill;
+use \OCA\Files_External\Lib\Backend\SMB;
/**
* Deprecated SMB_OC class - use SMB with the password::sessioncredentials auth mechanism
@@ -37,11 +38,11 @@ class SMB_OC extends Backend {
use LegacyDependencyCheckPolyfill;
- public function __construct(IL10N $l, SessionCredentials $legacyAuth) {
+ public function __construct(IL10N $l, SessionCredentials $legacyAuth, SMB $smbBackend) {
$this
->setIdentifier('\OC\Files\Storage\SMB_OC')
->setStorageClass('\OC\Files\Storage\SMB')
- ->setText($l->t('SMB / CIFS using OC login [DEPRECATED]'))
+ ->setText($l->t('SMB / CIFS using OC login'))
->addParameters([
(new DefinitionParameter('host', $l->t('Host'))),
(new DefinitionParameter('username_as_share', $l->t('Username as share')))
@@ -54,6 +55,7 @@ class SMB_OC extends Backend {
->setPriority(BackendService::PRIORITY_DEFAULT - 10)
->addAuthScheme(AuthMechanism::SCHEME_PASSWORD)
->setLegacyAuthMechanism($legacyAuth)
+ ->deprecateTo($smbBackend)
;
}