Move files_sharing Controllers => Controller

lib/Controller is the default location for controllers. So lets put them
all in there.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2016-10-24 11:46:25 +02:00
parent f054adb429
commit f589f1a1d6
No known key found for this signature in database
GPG Key ID: 1E152838F164D13B
6 changed files with 10 additions and 10 deletions

View File

@ -32,8 +32,8 @@ use OCA\Files_Sharing\Middleware\OCSShareAPIMiddleware;
use OCA\Files_Sharing\MountProvider;
use OCP\AppFramework\App;
use OC\AppFramework\Utility\SimpleContainer;
use OCA\Files_Sharing\Controllers\ExternalSharesController;
use OCA\Files_Sharing\Controllers\ShareController;
use OCA\Files_Sharing\Controller\ExternalSharesController;
use OCA\Files_Sharing\Controller\ShareController;
use OCA\Files_Sharing\Middleware\SharingCheckMiddleware;
use \OCP\IContainer;
use OCP\IServerContainer;

View File

@ -24,7 +24,7 @@
*
*/
namespace OCA\Files_Sharing\Controllers;
namespace OCA\Files_Sharing\Controller;
use OCP\AppFramework\Controller;
use OCP\IRequest;
@ -35,7 +35,7 @@ use OCP\AppFramework\Http\DataResponse;
/**
* Class ExternalSharesController
*
* @package OCA\Files_Sharing\Controllers
* @package OCA\Files_Sharing\Controller
*/
class ExternalSharesController extends Controller {

View File

@ -30,7 +30,7 @@
*
*/
namespace OCA\Files_Sharing\Controllers;
namespace OCA\Files_Sharing\Controller;
use OC_Files;
use OC_Util;

View File

@ -78,10 +78,10 @@ class SharingCheckMiddleware extends Middleware {
throw new NotFoundException('Sharing is disabled.');
}
if ($controller instanceof \OCA\Files_Sharing\Controllers\ExternalSharesController &&
if ($controller instanceof \OCA\Files_Sharing\Controller\ExternalSharesController &&
!$this->externalSharesChecks()) {
throw new S2SException('Federated sharing not allowed');
} else if ($controller instanceof \OCA\Files_Sharing\Controllers\ShareController &&
} else if ($controller instanceof \OCA\Files_Sharing\Controller\ShareController &&
!$this->isLinkSharingEnabled()) {
throw new NotFoundException('Link sharing is disabled');
}

View File

@ -24,7 +24,7 @@
namespace OCA\Files_Sharing\Tests\Controllers;
use OCA\Files_Sharing\Controllers\ExternalSharesController;
use OCA\Files_Sharing\Controller\ExternalSharesController;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Http\JSONResponse;
use OCP\Http\Client\IClientService;

View File

@ -33,7 +33,7 @@ namespace OCA\Files_Sharing\Tests\Controllers;
use OC\Files\Filesystem;
use OCA\FederatedFileSharing\FederatedShareProvider;
use OCA\Files_Sharing\Controllers\ShareController;
use OCA\Files_Sharing\Controller\ShareController;
use OCP\AppFramework\Http\DataResponse;
use OCP\Share\Exceptions\ShareNotFound;
use OCP\AppFramework\Http\NotFoundResponse;
@ -96,7 +96,7 @@ class ShareControllerTest extends \Test\TestCase {
->method('isIncomingServer2serverShareEnabled')->willReturn(true);
$this->eventDispatcher = $this->getMockBuilder('Symfony\Component\EventDispatcher\EventDispatcherInterface')->getMock();
$this->shareController = new \OCA\Files_Sharing\Controllers\ShareController(
$this->shareController = new \OCA\Files_Sharing\Controller\ShareController(
$this->appName,
$this->getMockBuilder('\OCP\IRequest')->getMock(),
$this->config,