summaryrefslogtreecommitdiffstats
path: root/lib/private
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private')
-rw-r--r--lib/private/DB/MigrationService.php24
-rw-r--r--lib/private/Files/Utils/Scanner.php5
-rw-r--r--lib/private/Template/IconsCacher.php2
3 files changed, 16 insertions, 15 deletions
diff --git a/lib/private/DB/MigrationService.php b/lib/private/DB/MigrationService.php
index cc2889dae0c..6f5a74103a5 100644
--- a/lib/private/DB/MigrationService.php
+++ b/lib/private/DB/MigrationService.php
@@ -376,13 +376,14 @@ class MigrationService {
* Applies all not yet applied versions up to $to
*
* @param string $to
+ * @param bool $schemaOnly
* @throws \InvalidArgumentException
*/
- public function migrate($to = 'latest') {
+ public function migrate($to = 'latest', $schemaOnly = false) {
// read known migrations
$toBeExecuted = $this->getMigrationsToExecute($to);
foreach ($toBeExecuted as $version) {
- $this->executeStep($version);
+ $this->executeStep($version, $schemaOnly);
}
}
@@ -432,14 +433,17 @@ class MigrationService {
* Executes one explicit version
*
* @param string $version
+ * @param bool $schemaOnly
* @throws \InvalidArgumentException
*/
- public function executeStep($version) {
+ public function executeStep($version, $schemaOnly = false) {
$instance = $this->createInstance($version);
- $instance->preSchemaChange($this->output, function() {
- return new SchemaWrapper($this->connection);
- }, ['tablePrefix' => $this->connection->getPrefix()]);
+ if (!$schemaOnly) {
+ $instance->preSchemaChange($this->output, function() {
+ return new SchemaWrapper($this->connection);
+ }, ['tablePrefix' => $this->connection->getPrefix()]);
+ }
$toSchema = $instance->changeSchema($this->output, function() {
return new SchemaWrapper($this->connection);
@@ -450,9 +454,11 @@ class MigrationService {
$toSchema->performDropTableCalls();
}
- $instance->postSchemaChange($this->output, function() {
- return new SchemaWrapper($this->connection);
- }, ['tablePrefix' => $this->connection->getPrefix()]);
+ if (!$schemaOnly) {
+ $instance->postSchemaChange($this->output, function() {
+ return new SchemaWrapper($this->connection);
+ }, ['tablePrefix' => $this->connection->getPrefix()]);
+ }
$this->markAsExecuted($version);
}
diff --git a/lib/private/Files/Utils/Scanner.php b/lib/private/Files/Utils/Scanner.php
index fe2bf4ccb58..28921973fcf 100644
--- a/lib/private/Files/Utils/Scanner.php
+++ b/lib/private/Files/Utils/Scanner.php
@@ -151,11 +151,6 @@ class Scanner extends PublicEmitter {
continue;
}
- // don't scan the root storage
- if ($storage->instanceOfStorage('\OC\Files\Storage\Local') && $mount->getMountPoint() === '/') {
- continue;
- }
-
// don't scan received local shares, these can be scanned when scanning the owner's storage
if ($storage->instanceOfStorage(SharedStorage::class)) {
continue;
diff --git a/lib/private/Template/IconsCacher.php b/lib/private/Template/IconsCacher.php
index c262d26654f..e5ebecaf169 100644
--- a/lib/private/Template/IconsCacher.php
+++ b/lib/private/Template/IconsCacher.php
@@ -47,7 +47,7 @@ class IconsCacher {
protected $urlGenerator;
/** @var string */
- private $iconVarRE = '/--(icon-[a-z0-9-]+): url\(["\']([a-z0-9-_\~\/\?\&\=\.]+)[^;]+;/m';
+ private $iconVarRE = '/--(icon-[a-zA-Z0-9-]+): url\(["\']([a-z0-9-_\~\/\.]+)[^;]+;/m';
/** @var string */
private $fileName = 'icons-vars.css';