Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Cleanup some PHPDoc leftovers and unused variables
Signed-off-by: Morris Jobke <[email protected]>
  • Loading branch information
MorrisJobke committed Mar 6, 2019
commit 3f9cdeeb5fe9aee97e410ec59bbdd1c9cf3c33d5
1 change: 0 additions & 1 deletion lib/private/Archive/Archive.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,6 @@ public abstract function getStream($path, $mode);
* add a folder and all its content
* @param string $path
* @param string $source
* @return boolean|null
*/
public function addRecursive($path, $source) {
$dh = opendir($source);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,19 +27,15 @@
use OCP\Collaboration\Collaborators\ISearchPlugin;
use OCP\Collaboration\Collaborators\ISearchResult;
use OCP\Collaboration\Collaborators\SearchResultType;
use OCP\Contacts\IManager;
use OCP\Federation\ICloudFederationProviderManager;
use OCP\Federation\ICloudIdManager;
use OCP\IConfig;
use OCP\Share;

class RemoteGroupPlugin implements ISearchPlugin {
protected $shareeEnumeration;

/** @var ICloudIdManager */
private $cloudIdManager;
/** @var IConfig */
private $config;
/** @var bool */
private $enabled = false;

Expand Down
6 changes: 0 additions & 6 deletions lib/private/Server.php
Original file line number Diff line number Diff line change
Expand Up @@ -497,8 +497,6 @@ public function __construct($webRoot, \OC\Config $config) {
ArrayCache::class
);
$config = $c->getConfig();
$request = $c->getRequest();
$urlGenerator = new URLGenerator($config, $arrayCacheFactory, $request);

if ($config->getSystemValue('installed', false) && !(defined('PHPUNIT_RUN') && PHPUNIT_RUN)) {
$v = \OC_App::getAppVersions();
Expand Down Expand Up @@ -970,8 +968,6 @@ public function __construct($webRoot, \OC\Config $config) {
return new \OC_Defaults();
});
$this->registerService(SCSSCacher::class, function (Server $c) {
/** @var Factory $cacheFactory */
$cacheFactory = $c->query(Factory::class);
return new SCSSCacher(
$c->getLogger(),
$c->query(\OC\Files\AppData\Factory::class),
Expand All @@ -985,8 +981,6 @@ public function __construct($webRoot, \OC\Config $config) {
);
});
$this->registerService(JSCombiner::class, function (Server $c) {
/** @var Factory $cacheFactory */
$cacheFactory = $c->query(Factory::class);
return new JSCombiner(
$c->getAppDataDir('js'),
$c->getURLGenerator(),
Expand Down
7 changes: 1 addition & 6 deletions lib/private/Setup/PostgreSQL.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,23 +77,18 @@ public function setupDatabase($username) {

//create the database
$this->createDatabase($connection);
$query = $connection->prepare("select count(*) FROM pg_class WHERE relname=? limit 1");
$query->execute([$this->tablePrefix . "users"]);
$tablesSetup = $query->fetchColumn() > 0;

// the connection to dbname=postgres is not needed anymore
$connection->close();
} catch (\Exception $e) {
$this->logger->logException($e);
$this->logger->warning('Error trying to connect as "postgres", assuming database is setup and tables need to be created');
$tablesSetup = false;
$this->config->setValues([
'dbuser' => $this->dbUser,
'dbpassword' => $this->dbPassword,
]);
}

// connect to the ownCloud database (dbname=$this->dbname) and check if it needs to be filled
// connect to the database (dbname=$this->dbname) and check if it needs to be filled
$this->dbUser = $this->config->getValue('dbuser');
$this->dbPassword = $this->config->getValue('dbpassword');
$connection = $this->connect();
Expand Down
2 changes: 1 addition & 1 deletion lib/private/Share20/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ public function createShare(\OCP\Share\IShare $share) {

// Pre share event
$event = new GenericEvent($share);
$a = $this->eventDispatcher->dispatch('OCP\Share::preShare', $event);
$this->eventDispatcher->dispatch('OCP\Share::preShare', $event);
if ($event->isPropagationStopped() && $event->hasArgument('error')) {
throw new \Exception($event->getArgument('error'));
}
Expand Down
1 change: 0 additions & 1 deletion lib/private/Template/Base.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,6 @@ public function assign( $key, $value) {
* Appends a variable
* @param string $key key
* @param mixed $value value
* @return boolean|null
*
* This function assigns a variable in an array context. If the key already
* exists, the value will be appended. It can be accessed via
Expand Down