aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/comments/appinfo/app.php11
-rw-r--r--apps/files_sharing/css/sharetabview.scss2
-rw-r--r--apps/user_ldap/lib/Access.php12
-rw-r--r--core/css/guest.css5
-rw-r--r--core/js/setupchecks.js9
-rw-r--r--core/js/tests/specs/setupchecksSpec.js59
-rw-r--r--core/templates/layout.guest.php1
-rw-r--r--lib/private/Server.php16
-rw-r--r--settings/Controller/CheckSetupController.php9
-rw-r--r--tests/Settings/Controller/CheckSetupControllerTest.php6
-rw-r--r--version.php4
11 files changed, 99 insertions, 35 deletions
diff --git a/apps/comments/appinfo/app.php b/apps/comments/appinfo/app.php
index e6974111811..15c545ae1e4 100644
--- a/apps/comments/appinfo/app.php
+++ b/apps/comments/appinfo/app.php
@@ -60,14 +60,3 @@ $commentsManager->registerEventHandler(function () {
$handler = $application->getContainer()->query(\OCA\Comments\EventHandler::class);
return $handler;
});
-$commentsManager->registerDisplayNameResolver('user', function($id) {
- $manager = \OC::$server->getUserManager();
- $user = $manager->get($id);
- if(is_null($user)) {
- $l = \OC::$server->getL10N('comments');
- $displayName = $l->t('Unknown user');
- } else {
- $displayName = $user->getDisplayName();
- }
- return $displayName;
-});
diff --git a/apps/files_sharing/css/sharetabview.scss b/apps/files_sharing/css/sharetabview.scss
index 4d07e547e86..6635546067b 100644
--- a/apps/files_sharing/css/sharetabview.scss
+++ b/apps/files_sharing/css/sharetabview.scss
@@ -14,7 +14,6 @@
}
.shareTabView .shareWithRemoteInfo,
-.shareTabView .clipboardButton,
.shareTabView .linkPass .icon-loading-small {
position: absolute;
right: -7px;
@@ -38,7 +37,6 @@
position: relative;
top: initial;
right: initial;
- padding: 18px 0 18px 36px;
}
.shareTabView label {
diff --git a/apps/user_ldap/lib/Access.php b/apps/user_ldap/lib/Access.php
index 95710cd37f2..27fda38a737 100644
--- a/apps/user_ldap/lib/Access.php
+++ b/apps/user_ldap/lib/Access.php
@@ -1253,11 +1253,13 @@ class Access extends LDAPUtility implements IUserTools {
unset($item[$key]['count']);
}
if($key !== 'dn') {
- $selection[$i][$key] = $this->resemblesDN($key) ?
- $this->helper->sanitizeDN($item[$key])
- : $key === 'objectguid' || $key === 'guid' ?
- $selection[$i][$key] = $this->convertObjectGUID2Str($item[$key])
- : $item[$key];
+ if($this->resemblesDN($key)) {
+ $selection[$i][$key] = $this->helper->sanitizeDN($item[$key]);
+ } else if($key === 'objectguid' || $key === 'guid') {
+ $selection[$i][$key] = [$this->convertObjectGUID2Str($item[$key][0])];
+ } else {
+ $selection[$i][$key] = $item[$key];
+ }
} else {
$selection[$i][$key] = [$this->helper->sanitizeDN($item[$key])];
}
diff --git a/core/css/guest.css b/core/css/guest.css
index b03e8d55efb..4256c66302f 100644
--- a/core/css/guest.css
+++ b/core/css/guest.css
@@ -86,7 +86,7 @@ body {
}
.wrapper {
width: 300px;
- margin-top: 10%;
+ margin-top: 10vh;
}
/* Default FORM */
@@ -721,8 +721,7 @@ img.icon-loading-small-dark, object.icon-loading-small-dark, video.icon-loading-
}
/* FOOTER */
-footer,
-.push {
+footer {
height: 70px;
margin-top: auto;
}
diff --git a/core/js/setupchecks.js b/core/js/setupchecks.js
index 44bf33dd711..439826161d8 100644
--- a/core/js/setupchecks.js
+++ b/core/js/setupchecks.js
@@ -174,6 +174,15 @@
type: OC.SetupChecks.MESSAGE_TYPE_WARNING
});
}
+ if (!data.hasFreeTypeSupport) {
+ messages.push({
+ msg: t(
+ 'core',
+ 'Your PHP does not have freetype support. This will result in broken profile pictures and settings interface.'
+ ),
+ type: OC.SetupChecks.MESSAGE_TYPE_INFO
+ })
+ }
} else {
messages.push({
msg: t('core', 'Error occurred while checking server setup'),
diff --git a/core/js/tests/specs/setupchecksSpec.js b/core/js/tests/specs/setupchecksSpec.js
index 0114f7d868f..00bc84f2a8f 100644
--- a/core/js/tests/specs/setupchecksSpec.js
+++ b/core/js/tests/specs/setupchecksSpec.js
@@ -156,7 +156,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -189,7 +190,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -223,7 +225,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -255,7 +258,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -285,7 +289,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: false,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -315,7 +320,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -345,7 +351,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: false
+ isSettimelimitAvailable: false,
+ hasFreeTypeSupport: true
})
);
@@ -396,7 +403,8 @@ describe('OC.SetupChecks tests', function() {
isCorrectMemcachedPHPModuleInstalled: true,
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: true,
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -427,7 +435,8 @@ describe('OC.SetupChecks tests', function() {
hasPassedCodeIntegrityCheck: true,
isOpcacheProperlySetup: false,
phpOpcacheDocumentation: 'https://example.org/link/to/doc',
- isSettimelimitAvailable: true
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: true
})
);
@@ -439,6 +448,38 @@ describe('OC.SetupChecks tests', function() {
done();
});
});
+
+ it('should return an info if server has no freetype support', function(done) {
+ var async = OC.SetupChecks.checkSetup();
+
+ suite.server.requests[0].respond(
+ 200,
+ {
+ 'Content-Type': 'application/json'
+ },
+ JSON.stringify({
+ isUrandomAvailable: true,
+ securityDocs: 'https://docs.owncloud.org/myDocs.html',
+ serverHasInternetConnection: true,
+ isMemcacheConfigured: true,
+ forwardedForHeadersWorking: true,
+ isCorrectMemcachedPHPModuleInstalled: true,
+ hasPassedCodeIntegrityCheck: true,
+ isOpcacheProperlySetup: true,
+ phpOpcacheDocumentation: 'https://example.org/link/to/doc',
+ isSettimelimitAvailable: true,
+ hasFreeTypeSupport: false
+ })
+ );
+
+ async.done(function( data, s, x ){
+ expect(data).toEqual([{
+ msg: 'Your PHP does not have freetype support. This will result in broken profile pictures and settings interface.',
+ type: OC.SetupChecks.MESSAGE_TYPE_INFO
+ }]);
+ done();
+ });
+ });
});
describe('checkGeneric', function() {
diff --git a/core/templates/layout.guest.php b/core/templates/layout.guest.php
index ce0eccb971d..4d06fc294d5 100644
--- a/core/templates/layout.guest.php
+++ b/core/templates/layout.guest.php
@@ -38,7 +38,6 @@
</header>
<?php endif; ?>
<?php print_unescaped($_['content']); ?>
- <div class="push"></div><!-- for sticky footer -->
</div>
</div>
<footer role="contentinfo">
diff --git a/lib/private/Server.php b/lib/private/Server.php
index 8a5fb0fa96c..6898e93e3bb 100644
--- a/lib/private/Server.php
+++ b/lib/private/Server.php
@@ -897,7 +897,21 @@ class Server extends ServerContainer implements IServerContainer {
$factoryClass = $config->getSystemValue('comments.managerFactory', '\OC\Comments\ManagerFactory');
/** @var \OCP\Comments\ICommentsManagerFactory $factory */
$factory = new $factoryClass($this);
- return $factory->getManager();
+ $manager = $factory->getManager();
+
+ $manager->registerDisplayNameResolver('user', function($id) use ($c) {
+ $manager = $c->getUserManager();
+ $user = $manager->get($id);
+ if(is_null($user)) {
+ $l = $c->getL10N('core');
+ $displayName = $l->t('Unknown user');
+ } else {
+ $displayName = $user->getDisplayName();
+ }
+ return $displayName;
+ });
+
+ return $manager;
});
$this->registerAlias('CommentsManager', \OCP\Comments\ICommentsManager::class);
diff --git a/settings/Controller/CheckSetupController.php b/settings/Controller/CheckSetupController.php
index 5b7953bf392..06b9e80294b 100644
--- a/settings/Controller/CheckSetupController.php
+++ b/settings/Controller/CheckSetupController.php
@@ -410,6 +410,14 @@ Raw output
}
/**
+ * Check if the required FreeType functions are present
+ * @return bool
+ */
+ protected function hasFreeTypeSupport() {
+ return function_exists('imagettfbbox') && function_exists('imagettftext');
+ }
+
+ /**
* @return DataResponse
*/
public function check() {
@@ -430,6 +438,7 @@ Raw output
'isOpcacheProperlySetup' => $this->isOpcacheProperlySetup(),
'phpOpcacheDocumentation' => $this->urlGenerator->linkToDocs('admin-php-opcache'),
'isSettimelimitAvailable' => $this->isSettimelimitAvailable(),
+ 'hasFreeTypeSupport' => $this->hasFreeTypeSupport(),
]
);
}
diff --git a/tests/Settings/Controller/CheckSetupControllerTest.php b/tests/Settings/Controller/CheckSetupControllerTest.php
index f0e203e714b..3f47819bcbd 100644
--- a/tests/Settings/Controller/CheckSetupControllerTest.php
+++ b/tests/Settings/Controller/CheckSetupControllerTest.php
@@ -96,7 +96,7 @@ class CheckSetupControllerTest extends TestCase {
$this->checker,
$this->logger
])
- ->setMethods(['getCurlVersion', 'isPhpOutdated', 'isOpcacheProperlySetup'])->getMock();
+ ->setMethods(['getCurlVersion', 'isPhpOutdated', 'isOpcacheProperlySetup', 'hasFreeTypeSupport'])->getMock();
}
public function testIsInternetConnectionWorkingDisabledViaConfig() {
@@ -321,6 +321,9 @@ class CheckSetupControllerTest extends TestCase {
->method('linkToDocs')
->with('admin-php-opcache')
->willReturn('http://docs.example.org/server/go.php?to=admin-php-opcache');
+ $this->checkSetupController
+ ->method('hasFreeTypeSupport')
+ ->willReturn(false);
$expected = new DataResponse(
[
@@ -342,6 +345,7 @@ class CheckSetupControllerTest extends TestCase {
'isOpcacheProperlySetup' => false,
'phpOpcacheDocumentation' => 'http://docs.example.org/server/go.php?to=admin-php-opcache',
'isSettimelimitAvailable' => true,
+ 'hasFreeTypeSupport' => false,
]
);
$this->assertEquals($expected, $this->checkSetupController->check());
diff --git a/version.php b/version.php
index 4841acdd1f6..53272cf32fe 100644
--- a/version.php
+++ b/version.php
@@ -29,10 +29,10 @@
// between betas, final and RCs. This is _not_ the public version number. Reset minor/patchlevel
// when updating major/minor version number.
-$OC_Version = array(13, 0, 0, 7);
+$OC_Version = array(13, 0, 0, 8);
// The human readable string
-$OC_VersionString = '13.0.0 Beta 2';
+$OC_VersionString = '13.0.0 Beta 3';
$OC_VersionCanBeUpgradedFrom = [
'nextcloud' => [