summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/composer/composer/autoload_classmap.php4
-rw-r--r--lib/composer/composer/autoload_static.php4
-rw-r--r--lib/l10n/it.js14
-rw-r--r--lib/l10n/it.json14
-rw-r--r--lib/l10n/sq.js9
-rw-r--r--lib/l10n/sq.json9
-rw-r--r--lib/private/DB/MigrationService.php6
-rw-r--r--lib/private/DB/SchemaWrapper.php2
-rw-r--r--lib/private/L10N/L10N.php8
-rw-r--r--lib/private/L10N/L10NString.php (renamed from lib/private/legacy/l10n/string.php)10
-rw-r--r--lib/private/Preview/Watcher.php8
-rw-r--r--lib/private/Setup.php3
-rw-r--r--lib/private/Setup/AbstractDatabase.php5
-rw-r--r--lib/private/Setup/MySQL.php6
-rw-r--r--lib/private/Setup/OCI.php9
-rw-r--r--lib/private/Setup/PostgreSQL.php5
-rw-r--r--lib/private/Setup/Sqlite.php1
-rw-r--r--lib/private/legacy/json.php2
-rw-r--r--lib/public/IL10N.php4
-rw-r--r--lib/public/Template.php2
20 files changed, 83 insertions, 42 deletions
diff --git a/lib/composer/composer/autoload_classmap.php b/lib/composer/composer/autoload_classmap.php
index 20e4f4358b3..09231824703 100644
--- a/lib/composer/composer/autoload_classmap.php
+++ b/lib/composer/composer/autoload_classmap.php
@@ -423,9 +423,9 @@ return array(
'OC\\Core\\Command\\Config\\System\\SetConfig' => $baseDir . '/core/Command/Config/System/SetConfig.php',
'OC\\Core\\Command\\Db\\ConvertMysqlToMB4' => $baseDir . '/core/Command/Db/ConvertMysqlToMB4.php',
'OC\\Core\\Command\\Db\\ConvertType' => $baseDir . '/core/Command/Db/ConvertType.php',
- 'OC\\Core\\Command\\Db\\GenerateChangeScript' => $baseDir . '/core/Command/Db/GenerateChangeScript.php',
'OC\\Core\\Command\\Db\\Migrations\\ExecuteCommand' => $baseDir . '/core/Command/Db/Migrations/ExecuteCommand.php',
'OC\\Core\\Command\\Db\\Migrations\\GenerateCommand' => $baseDir . '/core/Command/Db/Migrations/GenerateCommand.php',
+ 'OC\\Core\\Command\\Db\\Migrations\\GenerateFromSchemaFileCommand' => $baseDir . '/core/Command/Db/Migrations/GenerateFromSchemaFileCommand.php',
'OC\\Core\\Command\\Db\\Migrations\\MigrateCommand' => $baseDir . '/core/Command/Db/Migrations/MigrateCommand.php',
'OC\\Core\\Command\\Db\\Migrations\\StatusCommand' => $baseDir . '/core/Command/Db/Migrations/StatusCommand.php',
'OC\\Core\\Command\\Encryption\\ChangeKeyStorageRoot' => $baseDir . '/core/Command/Encryption/ChangeKeyStorageRoot.php',
@@ -489,6 +489,7 @@ return array(
'OC\\Core\\Controller\\UserController' => $baseDir . '/core/Controller/UserController.php',
'OC\\Core\\Middleware\\TwoFactorMiddleware' => $baseDir . '/core/Middleware/TwoFactorMiddleware.php',
'OC\\Core\\Migrations\\Version13000Date20170705121758' => $baseDir . '/core/Migrations/Version13000Date20170705121758.php',
+ 'OC\\Core\\Migrations\\Version13000Date20170718121200' => $baseDir . '/core/Migrations/Version13000Date20170718121200.php',
'OC\\DB\\Adapter' => $baseDir . '/lib/private/DB/Adapter.php',
'OC\\DB\\AdapterMySQL' => $baseDir . '/lib/private/DB/AdapterMySQL.php',
'OC\\DB\\AdapterOCI8' => $baseDir . '/lib/private/DB/AdapterOCI8.php',
@@ -664,6 +665,7 @@ return array(
'OC\\IntegrityCheck\\Iterator\\ExcludeFoldersByPathFilterIterator' => $baseDir . '/lib/private/IntegrityCheck/Iterator/ExcludeFoldersByPathFilterIterator.php',
'OC\\L10N\\Factory' => $baseDir . '/lib/private/L10N/Factory.php',
'OC\\L10N\\L10N' => $baseDir . '/lib/private/L10N/L10N.php',
+ 'OC\\L10N\\L10NString' => $baseDir . '/lib/private/L10N/L10NString.php',
'OC\\L10N\\LanguageNotFoundException' => $baseDir . '/lib/private/L10N/LanguageNotFoundException.php',
'OC\\LargeFileHelper' => $baseDir . '/lib/private/LargeFileHelper.php',
'OC\\Lock\\AbstractLockingProvider' => $baseDir . '/lib/private/Lock/AbstractLockingProvider.php',
diff --git a/lib/composer/composer/autoload_static.php b/lib/composer/composer/autoload_static.php
index 6eb8b44196a..8f23eb53ecf 100644
--- a/lib/composer/composer/autoload_static.php
+++ b/lib/composer/composer/autoload_static.php
@@ -453,9 +453,9 @@ class ComposerStaticInit53792487c5a8370acc0b06b1a864ff4c
'OC\\Core\\Command\\Config\\System\\SetConfig' => __DIR__ . '/../../..' . '/core/Command/Config/System/SetConfig.php',
'OC\\Core\\Command\\Db\\ConvertMysqlToMB4' => __DIR__ . '/../../..' . '/core/Command/Db/ConvertMysqlToMB4.php',
'OC\\Core\\Command\\Db\\ConvertType' => __DIR__ . '/../../..' . '/core/Command/Db/ConvertType.php',
- 'OC\\Core\\Command\\Db\\GenerateChangeScript' => __DIR__ . '/../../..' . '/core/Command/Db/GenerateChangeScript.php',
'OC\\Core\\Command\\Db\\Migrations\\ExecuteCommand' => __DIR__ . '/../../..' . '/core/Command/Db/Migrations/ExecuteCommand.php',
'OC\\Core\\Command\\Db\\Migrations\\GenerateCommand' => __DIR__ . '/../../..' . '/core/Command/Db/Migrations/GenerateCommand.php',
+ 'OC\\Core\\Command\\Db\\Migrations\\GenerateFromSchemaFileCommand' => __DIR__ . '/../../..' . '/core/Command/Db/Migrations/GenerateFromSchemaFileCommand.php',
'OC\\Core\\Command\\Db\\Migrations\\MigrateCommand' => __DIR__ . '/../../..' . '/core/Command/Db/Migrations/MigrateCommand.php',
'OC\\Core\\Command\\Db\\Migrations\\StatusCommand' => __DIR__ . '/../../..' . '/core/Command/Db/Migrations/StatusCommand.php',
'OC\\Core\\Command\\Encryption\\ChangeKeyStorageRoot' => __DIR__ . '/../../..' . '/core/Command/Encryption/ChangeKeyStorageRoot.php',
@@ -519,6 +519,7 @@ class ComposerStaticInit53792487c5a8370acc0b06b1a864ff4c
'OC\\Core\\Controller\\UserController' => __DIR__ . '/../../..' . '/core/Controller/UserController.php',
'OC\\Core\\Middleware\\TwoFactorMiddleware' => __DIR__ . '/../../..' . '/core/Middleware/TwoFactorMiddleware.php',
'OC\\Core\\Migrations\\Version13000Date20170705121758' => __DIR__ . '/../../..' . '/core/Migrations/Version13000Date20170705121758.php',
+ 'OC\\Core\\Migrations\\Version13000Date20170718121200' => __DIR__ . '/../../..' . '/core/Migrations/Version13000Date20170718121200.php',
'OC\\DB\\Adapter' => __DIR__ . '/../../..' . '/lib/private/DB/Adapter.php',
'OC\\DB\\AdapterMySQL' => __DIR__ . '/../../..' . '/lib/private/DB/AdapterMySQL.php',
'OC\\DB\\AdapterOCI8' => __DIR__ . '/../../..' . '/lib/private/DB/AdapterOCI8.php',
@@ -694,6 +695,7 @@ class ComposerStaticInit53792487c5a8370acc0b06b1a864ff4c
'OC\\IntegrityCheck\\Iterator\\ExcludeFoldersByPathFilterIterator' => __DIR__ . '/../../..' . '/lib/private/IntegrityCheck/Iterator/ExcludeFoldersByPathFilterIterator.php',
'OC\\L10N\\Factory' => __DIR__ . '/../../..' . '/lib/private/L10N/Factory.php',
'OC\\L10N\\L10N' => __DIR__ . '/../../..' . '/lib/private/L10N/L10N.php',
+ 'OC\\L10N\\L10NString' => __DIR__ . '/../../..' . '/lib/private/L10N/L10NString.php',
'OC\\L10N\\LanguageNotFoundException' => __DIR__ . '/../../..' . '/lib/private/L10N/LanguageNotFoundException.php',
'OC\\LargeFileHelper' => __DIR__ . '/../../..' . '/lib/private/LargeFileHelper.php',
'OC\\Lock\\AbstractLockingProvider' => __DIR__ . '/../../..' . '/lib/private/Lock/AbstractLockingProvider.php',
diff --git a/lib/l10n/it.js b/lib/l10n/it.js
index cb1d91e6d6b..d77a82343a8 100644
--- a/lib/l10n/it.js
+++ b/lib/l10n/it.js
@@ -47,6 +47,7 @@ OC.L10N.register(
"This is an automatically sent email, please do not reply." : "Questo è un messaggio di posta inviato automaticamente, non rispondere.",
"Help" : "Aiuto",
"Apps" : "Applicazioni",
+ "Settings" : "Impostazioni",
"Log out" : "Esci",
"Users" : "Utenti",
"APCu" : "APCu",
@@ -57,6 +58,13 @@ OC.L10N.register(
"Encryption" : "Cifratura",
"Additional settings" : "Impostazioni aggiuntive",
"Tips & tricks" : "Suggerimenti e trucchi",
+ "Personal info" : "Informazioni personali",
+ "Sync clients" : "Client di sincronizzazione",
+ "Unlimited" : "Illimitato",
+ "__language_name__" : "Italiano",
+ "Verifying" : "Verifica",
+ "Verifying …" : "Verifica in corso...",
+ "Verify" : "Verifica",
"%s enter the database username and name." : "%s digita il nome utente e il nome del database.",
"%s enter the database username." : "%s digita il nome utente del database.",
"%s enter the database name." : "%s digita il nome del database.",
@@ -104,7 +112,12 @@ OC.L10N.register(
"Sharing %s failed, because resharing is not allowed" : "Condivisione di %s non riuscita, poiché la ri-condivisione non è consentita",
"Sharing %s failed, because the sharing backend for %s could not find its source" : "Condivisione di %s non riuscita, poiché il motore di condivisione per %s non riesce a trovare la sua fonte",
"Sharing %s failed, because the file could not be found in the file cache" : "Condivisione di %s non riuscita, poiché il file non è stato trovato nella cache",
+ "Can’t increase permissions of %s" : "Impossibile aumentare i permessi di %s",
+ "Files can’t be shared with delete permissions" : "I file non possono essere condivisi con permessi di eliminazione",
+ "Files can’t be shared with create permissions" : "I file non possono essere condivisi con permessi di creazione",
"Expiration date is in the past" : "La data di scadenza è nel passato",
+ "Can’t set expiration date more than %s days in the future" : "Impossibile impostare la data di scadenza a più di %s giorni nel futuro",
+ "The requested share does not exist anymore" : "La condivisione richiesta non esiste più",
"Could not find category \"%s\"" : "Impossibile trovare la categoria \"%s\"",
"Sunday" : "Domenica",
"Monday" : "Lunedì",
@@ -197,6 +210,7 @@ OC.L10N.register(
"Your data directory must be an absolute path" : "La cartella dei dati deve essere un percorso assoluto",
"Check the value of \"datadirectory\" in your configuration" : "Controlla il valore di \"datadirectory\" nella tua configurazione",
"Your data directory is invalid" : "La cartella dei dati non è valida",
+ "Ensure there is a file called \".ocdata\" in the root of the data directory." : "Assicurati che ci sia un file \".ocdata\" nella radice della cartella data.",
"Could not obtain lock type %d on \"%s\"." : "Impossibile ottenere il blocco di tipo %d su \"%s\".",
"Storage unauthorized. %s" : "Archiviazione non autorizzata. %s",
"Storage incomplete configuration. %s" : "Configurazione dell'archiviazione incompleta.%s",
diff --git a/lib/l10n/it.json b/lib/l10n/it.json
index 8cd429ba9c1..388c6c95055 100644
--- a/lib/l10n/it.json
+++ b/lib/l10n/it.json
@@ -45,6 +45,7 @@
"This is an automatically sent email, please do not reply." : "Questo è un messaggio di posta inviato automaticamente, non rispondere.",
"Help" : "Aiuto",
"Apps" : "Applicazioni",
+ "Settings" : "Impostazioni",
"Log out" : "Esci",
"Users" : "Utenti",
"APCu" : "APCu",
@@ -55,6 +56,13 @@
"Encryption" : "Cifratura",
"Additional settings" : "Impostazioni aggiuntive",
"Tips & tricks" : "Suggerimenti e trucchi",
+ "Personal info" : "Informazioni personali",
+ "Sync clients" : "Client di sincronizzazione",
+ "Unlimited" : "Illimitato",
+ "__language_name__" : "Italiano",
+ "Verifying" : "Verifica",
+ "Verifying …" : "Verifica in corso...",
+ "Verify" : "Verifica",
"%s enter the database username and name." : "%s digita il nome utente e il nome del database.",
"%s enter the database username." : "%s digita il nome utente del database.",
"%s enter the database name." : "%s digita il nome del database.",
@@ -102,7 +110,12 @@
"Sharing %s failed, because resharing is not allowed" : "Condivisione di %s non riuscita, poiché la ri-condivisione non è consentita",
"Sharing %s failed, because the sharing backend for %s could not find its source" : "Condivisione di %s non riuscita, poiché il motore di condivisione per %s non riesce a trovare la sua fonte",
"Sharing %s failed, because the file could not be found in the file cache" : "Condivisione di %s non riuscita, poiché il file non è stato trovato nella cache",
+ "Can’t increase permissions of %s" : "Impossibile aumentare i permessi di %s",
+ "Files can’t be shared with delete permissions" : "I file non possono essere condivisi con permessi di eliminazione",
+ "Files can’t be shared with create permissions" : "I file non possono essere condivisi con permessi di creazione",
"Expiration date is in the past" : "La data di scadenza è nel passato",
+ "Can’t set expiration date more than %s days in the future" : "Impossibile impostare la data di scadenza a più di %s giorni nel futuro",
+ "The requested share does not exist anymore" : "La condivisione richiesta non esiste più",
"Could not find category \"%s\"" : "Impossibile trovare la categoria \"%s\"",
"Sunday" : "Domenica",
"Monday" : "Lunedì",
@@ -195,6 +208,7 @@
"Your data directory must be an absolute path" : "La cartella dei dati deve essere un percorso assoluto",
"Check the value of \"datadirectory\" in your configuration" : "Controlla il valore di \"datadirectory\" nella tua configurazione",
"Your data directory is invalid" : "La cartella dei dati non è valida",
+ "Ensure there is a file called \".ocdata\" in the root of the data directory." : "Assicurati che ci sia un file \".ocdata\" nella radice della cartella data.",
"Could not obtain lock type %d on \"%s\"." : "Impossibile ottenere il blocco di tipo %d su \"%s\".",
"Storage unauthorized. %s" : "Archiviazione non autorizzata. %s",
"Storage incomplete configuration. %s" : "Configurazione dell'archiviazione incompleta.%s",
diff --git a/lib/l10n/sq.js b/lib/l10n/sq.js
index 72df40ab6bc..8de60a08071 100644
--- a/lib/l10n/sq.js
+++ b/lib/l10n/sq.js
@@ -45,17 +45,21 @@ OC.L10N.register(
"This is an automatically sent email, please do not reply." : "Ky është një email i dërguar automatikisht, ju lutem mos u përgjigjni.",
"Help" : "Ndihmë",
"Apps" : "Aplikacione",
+ "Settings" : "Settings",
"Log out" : "Shkyçu",
"Users" : "Përdorues",
"APCu" : "APCu",
"Redis" : "Redis",
+ "Basic settings" : "Settings bazike",
"Sharing" : "Ndarja",
"Security" : "Siguria",
"Encryption" : "Enkriptimi",
"Additional settings" : "Konfigurime shtesë",
"Tips & tricks" : "Këshilla dhe rrengje",
"Personal info" : "Informacion personal",
- "Unlimited" : "E pa limituar",
+ "Sync clients" : "Klientë të sikronizuar",
+ "Unlimited" : "E palimituar",
+ "__language_name__" : "_emri_i_gjuhës__",
"Verifying" : "Duke e verifikuar",
"Verifying …" : "Duke e verifikuar ...",
"Verify" : "Verifiko",
@@ -189,7 +193,10 @@ OC.L10N.register(
"PostgreSQL >= 9 required" : "Lypset PostgreSQL >= 9",
"Please upgrade your database version" : "Ju lutemi, përmirësoni bazën tuaj të të dhënave me një version më të ri.",
"Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Ju lutemi, kalojani lejet në 0770, që kështu atë drejtori të mos mund ta shfaqin përdorues të tjerë.",
+ "Your data directory is readable by other users" : "Direktoria juaj e të dhënave është e lexueshme nga përdorues të tjerë",
+ "Your data directory must be an absolute path" : "Direktoria juaj e të dhënave duhet të jetë një path absolut",
"Check the value of \"datadirectory\" in your configuration" : "Kontrolloni vlerën e \"datadirectory\" te formësimi juaj",
+ "Your data directory is invalid" : "Direktoria juaj e të dhënave është i pavlefshëm",
"Could not obtain lock type %d on \"%s\"." : "S’u mor dot lloj kyçjeje %d në \"%s\".",
"Storage unauthorized. %s" : "Depozitë e paautorizuar. %s",
"Storage incomplete configuration. %s" : "Formësim jo i plotë i depozitës. %s",
diff --git a/lib/l10n/sq.json b/lib/l10n/sq.json
index 4ca0cb1c20a..bc20a1d9ad2 100644
--- a/lib/l10n/sq.json
+++ b/lib/l10n/sq.json
@@ -43,17 +43,21 @@
"This is an automatically sent email, please do not reply." : "Ky është një email i dërguar automatikisht, ju lutem mos u përgjigjni.",
"Help" : "Ndihmë",
"Apps" : "Aplikacione",
+ "Settings" : "Settings",
"Log out" : "Shkyçu",
"Users" : "Përdorues",
"APCu" : "APCu",
"Redis" : "Redis",
+ "Basic settings" : "Settings bazike",
"Sharing" : "Ndarja",
"Security" : "Siguria",
"Encryption" : "Enkriptimi",
"Additional settings" : "Konfigurime shtesë",
"Tips & tricks" : "Këshilla dhe rrengje",
"Personal info" : "Informacion personal",
- "Unlimited" : "E pa limituar",
+ "Sync clients" : "Klientë të sikronizuar",
+ "Unlimited" : "E palimituar",
+ "__language_name__" : "_emri_i_gjuhës__",
"Verifying" : "Duke e verifikuar",
"Verifying …" : "Duke e verifikuar ...",
"Verify" : "Verifiko",
@@ -187,7 +191,10 @@
"PostgreSQL >= 9 required" : "Lypset PostgreSQL >= 9",
"Please upgrade your database version" : "Ju lutemi, përmirësoni bazën tuaj të të dhënave me një version më të ri.",
"Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Ju lutemi, kalojani lejet në 0770, që kështu atë drejtori të mos mund ta shfaqin përdorues të tjerë.",
+ "Your data directory is readable by other users" : "Direktoria juaj e të dhënave është e lexueshme nga përdorues të tjerë",
+ "Your data directory must be an absolute path" : "Direktoria juaj e të dhënave duhet të jetë një path absolut",
"Check the value of \"datadirectory\" in your configuration" : "Kontrolloni vlerën e \"datadirectory\" te formësimi juaj",
+ "Your data directory is invalid" : "Direktoria juaj e të dhënave është i pavlefshëm",
"Could not obtain lock type %d on \"%s\"." : "S’u mor dot lloj kyçjeje %d në \"%s\".",
"Storage unauthorized. %s" : "Depozitë e paautorizuar. %s",
"Storage incomplete configuration. %s" : "Formësim jo i plotë i depozitës. %s",
diff --git a/lib/private/DB/MigrationService.php b/lib/private/DB/MigrationService.php
index 92041b5e324..45f6aee83f6 100644
--- a/lib/private/DB/MigrationService.php
+++ b/lib/private/DB/MigrationService.php
@@ -284,7 +284,8 @@ class MigrationService {
case 'latest':
$this->ensureMigrationsAreLoaded();
- return @end($this->getAvailableVersions());
+ $migrations = $this->getAvailableVersions();
+ return @end($migrations);
}
return '0';
}
@@ -316,7 +317,8 @@ class MigrationService {
if (count($m) === 0) {
return '0';
}
- return @end(array_values($m));
+ $migrations = array_values($m);
+ return @end($migrations);
}
/**
diff --git a/lib/private/DB/SchemaWrapper.php b/lib/private/DB/SchemaWrapper.php
index 0be45d8d3f7..d686d7e63e5 100644
--- a/lib/private/DB/SchemaWrapper.php
+++ b/lib/private/DB/SchemaWrapper.php
@@ -34,7 +34,7 @@ class SchemaWrapper {
protected $schema;
/** @var array */
- protected $tablesToDelete;
+ protected $tablesToDelete = [];
/**
* @param IDBConnection $connection
diff --git a/lib/private/L10N/L10N.php b/lib/private/L10N/L10N.php
index c83b6ea3960..b933048982f 100644
--- a/lib/private/L10N/L10N.php
+++ b/lib/private/L10N/L10N.php
@@ -82,7 +82,7 @@ class L10N implements IL10N {
* returned.
*/
public function t($text, $parameters = array()) {
- return (string) new \OC_L10N_String($this, $text, $parameters);
+ return (string) new L10NString($this, $text, $parameters);
}
/**
@@ -103,12 +103,12 @@ class L10N implements IL10N {
public function n($text_singular, $text_plural, $count, $parameters = array()) {
$identifier = "_${text_singular}_::_${text_plural}_";
if (isset($this->translations[$identifier])) {
- return (string) new \OC_L10N_String($this, $identifier, $parameters, $count);
+ return (string) new L10NString($this, $identifier, $parameters, $count);
} else {
if ($count === 1) {
- return (string) new \OC_L10N_String($this, $text_singular, $parameters, $count);
+ return (string) new L10NString($this, $text_singular, $parameters, $count);
} else {
- return (string) new \OC_L10N_String($this, $text_plural, $parameters, $count);
+ return (string) new L10NString($this, $text_plural, $parameters, $count);
}
}
}
diff --git a/lib/private/legacy/l10n/string.php b/lib/private/L10N/L10NString.php
index 1410db6d730..fd2f14f9f28 100644
--- a/lib/private/legacy/l10n/string.php
+++ b/lib/private/L10N/L10NString.php
@@ -26,7 +26,9 @@
*
*/
-class OC_L10N_String implements JsonSerializable {
+namespace OC\L10N;
+
+class L10NString implements \JsonSerializable {
/** @var \OC\L10N\L10N */
protected $l10n;
@@ -52,6 +54,9 @@ class OC_L10N_String implements JsonSerializable {
$this->count = $count;
}
+ /**
+ * @return string
+ */
public function __toString() {
$translations = $this->l10n->getTranslations();
@@ -73,6 +78,9 @@ class OC_L10N_String implements JsonSerializable {
}
+ /**
+ * @return string
+ */
public function jsonSerialize() {
return $this->__toString();
}
diff --git a/lib/private/Preview/Watcher.php b/lib/private/Preview/Watcher.php
index 0b87bcda86e..8d091b84b0e 100644
--- a/lib/private/Preview/Watcher.php
+++ b/lib/private/Preview/Watcher.php
@@ -77,10 +77,16 @@ class Watcher {
}
/** @var Folder $node */
- $nodes = $node->search('');
+ $this->deleteFolder($node);
+ }
+
+ private function deleteFolder(Folder $folder) {
+ $nodes = $folder->getDirectoryListing();
foreach ($nodes as $node) {
if ($node instanceof File) {
$this->toDelete[] = $node->getId();
+ } else if ($node instanceof Folder) {
+ $this->deleteFolder($node);
}
}
}
diff --git a/lib/private/Setup.php b/lib/private/Setup.php
index 5cd3c84ce92..f5bfca604a9 100644
--- a/lib/private/Setup.php
+++ b/lib/private/Setup.php
@@ -282,8 +282,7 @@ class Setup {
$class = self::$dbSetupClasses[$dbType];
/** @var \OC\Setup\AbstractDatabase $dbSetup */
- $dbSetup = new $class($l, 'db_structure.xml', $this->config,
- $this->logger, $this->random);
+ $dbSetup = new $class($l, $this->config, $this->logger, $this->random);
$error = array_merge($error, $dbSetup->validate($options));
// validate the data directory
diff --git a/lib/private/Setup/AbstractDatabase.php b/lib/private/Setup/AbstractDatabase.php
index 2fbec326a5d..0e0981e0771 100644
--- a/lib/private/Setup/AbstractDatabase.php
+++ b/lib/private/Setup/AbstractDatabase.php
@@ -38,8 +38,6 @@ abstract class AbstractDatabase {
/** @var IL10N */
protected $trans;
/** @var string */
- protected $dbDefinitionFile;
- /** @var string */
protected $dbUser;
/** @var string */
protected $dbPassword;
@@ -58,9 +56,8 @@ abstract class AbstractDatabase {
/** @var ISecureRandom */
protected $random;
- public function __construct(IL10N $trans, $dbDefinitionFile, SystemConfig $config, ILogger $logger, ISecureRandom $random) {
+ public function __construct(IL10N $trans, SystemConfig $config, ILogger $logger, ISecureRandom $random) {
$this->trans = $trans;
- $this->dbDefinitionFile = $dbDefinitionFile;
$this->config = $config;
$this->logger = $logger;
$this->random = $random;
diff --git a/lib/private/Setup/MySQL.php b/lib/private/Setup/MySQL.php
index b4ca02d2e84..d03e4858b61 100644
--- a/lib/private/Setup/MySQL.php
+++ b/lib/private/Setup/MySQL.php
@@ -51,11 +51,7 @@ class MySQL extends AbstractDatabase {
//fill the database if needed
$query='select count(*) from information_schema.tables where table_schema=? AND table_name = ?';
- $result = $connection->executeQuery($query, [$this->dbName, $this->tablePrefix.'users']);
- $row = $result->fetch();
- if (!$row or $row['count(*)'] === '0') {
- \OC_DB::createDbFromStructure($this->dbDefinitionFile);
- }
+ $connection->executeQuery($query, [$this->dbName, $this->tablePrefix.'users']);
}
/**
diff --git a/lib/private/Setup/OCI.php b/lib/private/Setup/OCI.php
index 1bc6b08117f..3051987917c 100644
--- a/lib/private/Setup/OCI.php
+++ b/lib/private/Setup/OCI.php
@@ -165,14 +165,7 @@ class OCI extends AbstractDatabase {
$entry .= $this->trans->t('Offending command was: "%s"', array($query)) . '<br />';
$this->logger->warning( $entry, ['app' => 'setup.oci']);
}
- $result = oci_execute($stmt);
-
- if($result) {
- $row = oci_fetch_row($stmt);
- }
- if(!$result or $row[0]==0) {
- \OC_DB::createDbFromStructure($this->dbDefinitionFile);
- }
+ oci_execute($stmt);
}
/**
diff --git a/lib/private/Setup/PostgreSQL.php b/lib/private/Setup/PostgreSQL.php
index 8267b065142..dbcb94d6d7f 100644
--- a/lib/private/Setup/PostgreSQL.php
+++ b/lib/private/Setup/PostgreSQL.php
@@ -105,11 +105,6 @@ class PostgreSQL extends AbstractDatabase {
throw new \OC\DatabaseSetupException($this->trans->t('PostgreSQL username and/or password not valid'),
$this->trans->t('You need to enter details of an existing account.'));
}
-
-
- if (!$tablesSetup) {
- \OC_DB::createDbFromStructure($this->dbDefinitionFile);
- }
}
private function createDatabase(IDBConnection $connection) {
diff --git a/lib/private/Setup/Sqlite.php b/lib/private/Setup/Sqlite.php
index 87c0b82682f..d95e70c8b0c 100644
--- a/lib/private/Setup/Sqlite.php
+++ b/lib/private/Setup/Sqlite.php
@@ -41,6 +41,5 @@ class Sqlite extends AbstractDatabase {
}
//in case of sqlite, we can always fill the database
error_log("creating sqlite db");
- \OC_DB::createDbFromStructure($this->dbDefinitionFile);
}
}
diff --git a/lib/private/legacy/json.php b/lib/private/legacy/json.php
index 0e598a68ee1..9b90daccac9 100644
--- a/lib/private/legacy/json.php
+++ b/lib/private/legacy/json.php
@@ -159,7 +159,7 @@ class OC_JSON{
* Convert OC_L10N_String to string, for use in json encodings
*/
protected static function to_string(&$value) {
- if ($value instanceof OC_L10N_String) {
+ if ($value instanceof \OC\L10N\L10NString) {
$value = (string)$value;
}
}
diff --git a/lib/public/IL10N.php b/lib/public/IL10N.php
index 0dfe28c2ce8..7856a74219d 100644
--- a/lib/public/IL10N.php
+++ b/lib/public/IL10N.php
@@ -47,7 +47,7 @@ interface IL10N {
* Translating
* @param string $text The text we need a translation for
* @param array $parameters default:array() Parameters for sprintf
- * @return \OC_L10N_String Translation or the same text
+ * @return string Translation or the same text
*
* Returns the translation. If no translation is found, $text will be
* returned.
@@ -61,7 +61,7 @@ interface IL10N {
* @param string $text_plural the string to translate for n objects
* @param integer $count Number of objects
* @param array $parameters default:array() Parameters for sprintf
- * @return \OC_L10N_String Translation or the same text
+ * @return string Translation or the same text
*
* Returns the translation. If no translation is found, $text will be
* returned. %n will be replaced with the number of objects.
diff --git a/lib/public/Template.php b/lib/public/Template.php
index 85c60cfb0a2..3dcee14d880 100644
--- a/lib/public/Template.php
+++ b/lib/public/Template.php
@@ -102,7 +102,7 @@ function human_file_size($bytes) {
* Return the relative date in relation to today. Returns something like "last hour" or "two month ago"
* @param int $timestamp unix timestamp
* @param boolean $dateOnly
- * @return \OC_L10N_String human readable interpretation of the timestamp
+ * @return string human readable interpretation of the timestamp
*
* @deprecated 8.0.0 Use \OCP\Template::relative_modified_date() instead
*/