diff --git a/src/Api/Controller/CreateDiscussionController.php b/src/Api/Controller/CreateDiscussionController.php index ab6eb9cde..69f2afc15 100644 --- a/src/Api/Controller/CreateDiscussionController.php +++ b/src/Api/Controller/CreateDiscussionController.php @@ -11,8 +11,8 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\ReadDiscussion; -use Flarum\Core\Command\StartDiscussion; +use Flarum\Discussion\Command\ReadDiscussion; +use Flarum\Discussion\Command\StartDiscussion; use Flarum\Post\Floodgate; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/CreateGroupController.php b/src/Api/Controller/CreateGroupController.php index 977ae9c62..9bf23052f 100644 --- a/src/Api/Controller/CreateGroupController.php +++ b/src/Api/Controller/CreateGroupController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\CreateGroup; +use Flarum\Group\Command\CreateGroup; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Api/Controller/CreatePostController.php b/src/Api/Controller/CreatePostController.php index a268b7d21..fc7432530 100644 --- a/src/Api/Controller/CreatePostController.php +++ b/src/Api/Controller/CreatePostController.php @@ -11,8 +11,8 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\PostReply; -use Flarum\Core\Command\ReadDiscussion; +use Flarum\Discussion\Command\ReadDiscussion; +use Flarum\Post\Command\PostReply; use Flarum\Post\Floodgate; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/CreateUserController.php b/src/Api/Controller/CreateUserController.php index 608cd039d..155f862ac 100644 --- a/src/Api/Controller/CreateUserController.php +++ b/src/Api/Controller/CreateUserController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\RegisterUser; +use Flarum\User\Command\RegisterUser; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Api/Controller/DeleteAvatarController.php b/src/Api/Controller/DeleteAvatarController.php index 73cbe9dd1..61ab87109 100644 --- a/src/Api/Controller/DeleteAvatarController.php +++ b/src/Api/Controller/DeleteAvatarController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\DeleteAvatar; +use Flarum\User\Command\DeleteAvatar; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Api/Controller/DeleteDiscussionController.php b/src/Api/Controller/DeleteDiscussionController.php index 793c34273..17c0206d6 100644 --- a/src/Api/Controller/DeleteDiscussionController.php +++ b/src/Api/Controller/DeleteDiscussionController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\DeleteDiscussion; +use Flarum\Discussion\Command\DeleteDiscussion; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/DeleteGroupController.php b/src/Api/Controller/DeleteGroupController.php index 051edea19..e4f1adb61 100644 --- a/src/Api/Controller/DeleteGroupController.php +++ b/src/Api/Controller/DeleteGroupController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\DeleteGroup; +use Flarum\Group\Command\DeleteGroup; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/DeletePostController.php b/src/Api/Controller/DeletePostController.php index 1b3ea47e1..eb1bd812c 100644 --- a/src/Api/Controller/DeletePostController.php +++ b/src/Api/Controller/DeletePostController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\DeletePost; +use Flarum\Post\Command\DeletePost; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/DeleteUserController.php b/src/Api/Controller/DeleteUserController.php index 6f3a7fb42..2d00d8897 100644 --- a/src/Api/Controller/DeleteUserController.php +++ b/src/Api/Controller/DeleteUserController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\DeleteUser; +use Flarum\User\Command\DeleteUser; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/ForgotPasswordController.php b/src/Api/Controller/ForgotPasswordController.php index 5516c6d47..56e638878 100644 --- a/src/Api/Controller/ForgotPasswordController.php +++ b/src/Api/Controller/ForgotPasswordController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\RequestPasswordReset; +use Flarum\User\Command\RequestPasswordReset; use Flarum\User\UserRepository; use Flarum\Http\Controller\ControllerInterface; use Illuminate\Contracts\Bus\Dispatcher; diff --git a/src/Api/Controller/ReadAllNotificationsController.php b/src/Api/Controller/ReadAllNotificationsController.php index 231f743ff..c60230fa5 100644 --- a/src/Api/Controller/ReadAllNotificationsController.php +++ b/src/Api/Controller/ReadAllNotificationsController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\ReadAllNotifications; +use Flarum\Notification\Command\ReadAllNotifications; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/UpdateDiscussionController.php b/src/Api/Controller/UpdateDiscussionController.php index 09ba078c5..4cdd3a0a1 100644 --- a/src/Api/Controller/UpdateDiscussionController.php +++ b/src/Api/Controller/UpdateDiscussionController.php @@ -11,8 +11,8 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\EditDiscussion; -use Flarum\Core\Command\ReadDiscussion; +use Flarum\Discussion\Command\EditDiscussion; +use Flarum\Discussion\Command\ReadDiscussion; use Illuminate\Contracts\Bus\Dispatcher; use Illuminate\Database\Eloquent\Collection; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/UpdateGroupController.php b/src/Api/Controller/UpdateGroupController.php index ccb6a8b6e..c4bd8f5dd 100644 --- a/src/Api/Controller/UpdateGroupController.php +++ b/src/Api/Controller/UpdateGroupController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\EditGroup; +use Flarum\Group\Command\EditGroup; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Api/Controller/UpdateNotificationController.php b/src/Api/Controller/UpdateNotificationController.php index 01e305bc7..f459e0338 100644 --- a/src/Api/Controller/UpdateNotificationController.php +++ b/src/Api/Controller/UpdateNotificationController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\ReadNotification; +use Flarum\Notification\Command\ReadNotification; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Api/Controller/UpdatePostController.php b/src/Api/Controller/UpdatePostController.php index bb5a5f08a..6f13e3371 100644 --- a/src/Api/Controller/UpdatePostController.php +++ b/src/Api/Controller/UpdatePostController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\EditPost; +use Flarum\Post\Command\EditPost; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Api/Controller/UpdateUserController.php b/src/Api/Controller/UpdateUserController.php index 818e4d941..42a57754a 100644 --- a/src/Api/Controller/UpdateUserController.php +++ b/src/Api/Controller/UpdateUserController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\EditUser; +use Flarum\User\Command\EditUser; use Flarum\User\Exception\PermissionDeniedException; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; diff --git a/src/Api/Controller/UploadAvatarController.php b/src/Api/Controller/UploadAvatarController.php index ac3619d24..b2e23e33b 100644 --- a/src/Api/Controller/UploadAvatarController.php +++ b/src/Api/Controller/UploadAvatarController.php @@ -11,7 +11,7 @@ namespace Flarum\Api\Controller; -use Flarum\Core\Command\UploadAvatar; +use Flarum\User\Command\UploadAvatar; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Tobscure\JsonApi\Document; diff --git a/src/Core/Command/DeleteDiscussion.php b/src/Discussion/Command/DeleteDiscussion.php similarity index 96% rename from src/Core/Command/DeleteDiscussion.php rename to src/Discussion/Command/DeleteDiscussion.php index 3c4d1219b..f79525fb6 100644 --- a/src/Core/Command/DeleteDiscussion.php +++ b/src/Discussion/Command/DeleteDiscussion.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; use Flarum\User\User; diff --git a/src/Core/Command/DeleteDiscussionHandler.php b/src/Discussion/Command/DeleteDiscussionHandler.php similarity index 97% rename from src/Core/Command/DeleteDiscussionHandler.php rename to src/Discussion/Command/DeleteDiscussionHandler.php index 9643b5e96..de0bb03b3 100644 --- a/src/Core/Command/DeleteDiscussionHandler.php +++ b/src/Discussion/Command/DeleteDiscussionHandler.php @@ -9,13 +9,13 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; +use Flarum\Discussion\DiscussionRepository; +use Flarum\Discussion\Event\Deleting; +use Flarum\Foundation\DispatchEventsTrait; use Flarum\User\AssertPermissionTrait; use Flarum\User\Exception\PermissionDeniedException; -use Flarum\Discussion\DiscussionRepository; -use Flarum\Foundation\DispatchEventsTrait; -use Flarum\Discussion\Event\Deleting; use Illuminate\Contracts\Events\Dispatcher; class DeleteDiscussionHandler diff --git a/src/Core/Command/EditDiscussion.php b/src/Discussion/Command/EditDiscussion.php similarity index 96% rename from src/Core/Command/EditDiscussion.php rename to src/Discussion/Command/EditDiscussion.php index 4ae77a276..660ed8b0d 100644 --- a/src/Core/Command/EditDiscussion.php +++ b/src/Discussion/Command/EditDiscussion.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; use Flarum\User\User; diff --git a/src/Core/Command/EditDiscussionHandler.php b/src/Discussion/Command/EditDiscussionHandler.php similarity index 96% rename from src/Core/Command/EditDiscussionHandler.php rename to src/Discussion/Command/EditDiscussionHandler.php index 038777d3e..42e38f9e9 100644 --- a/src/Core/Command/EditDiscussionHandler.php +++ b/src/Discussion/Command/EditDiscussionHandler.php @@ -9,14 +9,13 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\Exception\PermissionDeniedException; use Flarum\Discussion\DiscussionRepository; -use Flarum\Foundation\DispatchEventsTrait; use Flarum\Discussion\DiscussionValidator; use Flarum\Discussion\Event\Saving; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Events\Dispatcher; class EditDiscussionHandler diff --git a/src/Core/Command/ReadDiscussion.php b/src/Discussion/Command/ReadDiscussion.php similarity index 96% rename from src/Core/Command/ReadDiscussion.php rename to src/Discussion/Command/ReadDiscussion.php index 4a0c8ebd4..c6a8826e3 100644 --- a/src/Core/Command/ReadDiscussion.php +++ b/src/Discussion/Command/ReadDiscussion.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; use Flarum\User\User; diff --git a/src/Core/Command/ReadDiscussionHandler.php b/src/Discussion/Command/ReadDiscussionHandler.php similarity index 97% rename from src/Core/Command/ReadDiscussionHandler.php rename to src/Discussion/Command/ReadDiscussionHandler.php index dea81e8b6..0197d8684 100644 --- a/src/Core/Command/ReadDiscussionHandler.php +++ b/src/Discussion/Command/ReadDiscussionHandler.php @@ -9,12 +9,12 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; -use Flarum\User\AssertPermissionTrait; use Flarum\Discussion\DiscussionRepository; -use Flarum\Foundation\DispatchEventsTrait; use Flarum\Discussion\Event\UserDataSaving; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Events\Dispatcher; class ReadDiscussionHandler diff --git a/src/Core/Command/StartDiscussion.php b/src/Discussion/Command/StartDiscussion.php similarity index 95% rename from src/Core/Command/StartDiscussion.php rename to src/Discussion/Command/StartDiscussion.php index 9bc0cab10..3b564c0f1 100644 --- a/src/Core/Command/StartDiscussion.php +++ b/src/Discussion/Command/StartDiscussion.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; use Flarum\User\User; diff --git a/src/Core/Command/StartDiscussionHandler.php b/src/Discussion/Command/StartDiscussionHandler.php similarity index 98% rename from src/Core/Command/StartDiscussionHandler.php rename to src/Discussion/Command/StartDiscussionHandler.php index 7f8586031..01f99b832 100644 --- a/src/Core/Command/StartDiscussionHandler.php +++ b/src/Discussion/Command/StartDiscussionHandler.php @@ -9,14 +9,14 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Discussion\Command; use Exception; -use Flarum\User\AssertPermissionTrait; use Flarum\Discussion\Discussion; -use Flarum\Foundation\DispatchEventsTrait; use Flarum\Discussion\DiscussionValidator; use Flarum\Discussion\Event\Saving; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher; use Illuminate\Contracts\Events\Dispatcher as EventDispatcher; diff --git a/src/Forum/Controller/ConfirmEmailController.php b/src/Forum/Controller/ConfirmEmailController.php index 0284674ed..5889fdfb6 100644 --- a/src/Forum/Controller/ConfirmEmailController.php +++ b/src/Forum/Controller/ConfirmEmailController.php @@ -11,11 +11,11 @@ namespace Flarum\Forum\Controller; -use Flarum\Core\Command\ConfirmEmail; -use Flarum\User\Exception\InvalidConfirmationTokenException; use Flarum\Foundation\Application; use Flarum\Http\Controller\ControllerInterface; use Flarum\Http\SessionAuthenticator; +use Flarum\User\Command\ConfirmEmail; +use Flarum\User\Exception\InvalidConfirmationTokenException; use Illuminate\Contracts\Bus\Dispatcher; use Psr\Http\Message\ServerRequestInterface as Request; use Zend\Diactoros\Response\HtmlResponse; diff --git a/src/Core/Command/CreateGroup.php b/src/Group/Command/CreateGroup.php similarity index 95% rename from src/Core/Command/CreateGroup.php rename to src/Group/Command/CreateGroup.php index e67eefea6..e20fb6154 100644 --- a/src/Core/Command/CreateGroup.php +++ b/src/Group/Command/CreateGroup.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Group\Command; use Flarum\User\User; diff --git a/src/Core/Command/CreateGroupHandler.php b/src/Group/Command/CreateGroupHandler.php similarity index 98% rename from src/Core/Command/CreateGroupHandler.php rename to src/Group/Command/CreateGroupHandler.php index ee152d1ec..e18ac566b 100644 --- a/src/Core/Command/CreateGroupHandler.php +++ b/src/Group/Command/CreateGroupHandler.php @@ -9,13 +9,13 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Group\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\Group\Group; use Flarum\Foundation\DispatchEventsTrait; -use Flarum\Group\GroupValidator; use Flarum\Group\Event\Saving; +use Flarum\Group\Group; +use Flarum\Group\GroupValidator; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Events\Dispatcher; class CreateGroupHandler diff --git a/src/Core/Command/DeleteGroup.php b/src/Group/Command/DeleteGroup.php similarity index 97% rename from src/Core/Command/DeleteGroup.php rename to src/Group/Command/DeleteGroup.php index b57bc7c33..b2bb6873e 100644 --- a/src/Core/Command/DeleteGroup.php +++ b/src/Group/Command/DeleteGroup.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Group\Command; use Flarum\User\User; diff --git a/src/Core/Command/DeleteGroupHandler.php b/src/Group/Command/DeleteGroupHandler.php similarity index 97% rename from src/Core/Command/DeleteGroupHandler.php rename to src/Group/Command/DeleteGroupHandler.php index 119758d1f..568f92802 100644 --- a/src/Core/Command/DeleteGroupHandler.php +++ b/src/Group/Command/DeleteGroupHandler.php @@ -9,13 +9,13 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Group\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\Exception\PermissionDeniedException; -use Flarum\Group\GroupRepository; use Flarum\Foundation\DispatchEventsTrait; use Flarum\Group\Event\Deleting; +use Flarum\Group\GroupRepository; +use Flarum\User\AssertPermissionTrait; +use Flarum\User\Exception\PermissionDeniedException; use Illuminate\Contracts\Events\Dispatcher; class DeleteGroupHandler diff --git a/src/Core/Command/EditGroup.php b/src/Group/Command/EditGroup.php similarity index 96% rename from src/Core/Command/EditGroup.php rename to src/Group/Command/EditGroup.php index f05dc26cd..e64cb9913 100644 --- a/src/Core/Command/EditGroup.php +++ b/src/Group/Command/EditGroup.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Group\Command; use Flarum\User\User; diff --git a/src/Core/Command/EditGroupHandler.php b/src/Group/Command/EditGroupHandler.php similarity index 98% rename from src/Core/Command/EditGroupHandler.php rename to src/Group/Command/EditGroupHandler.php index c3fee99f4..d82020328 100644 --- a/src/Core/Command/EditGroupHandler.php +++ b/src/Group/Command/EditGroupHandler.php @@ -9,15 +9,15 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Group\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\Exception\PermissionDeniedException; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\Group\Event\Saving; use Flarum\Group\Group; use Flarum\Group\GroupRepository; -use Flarum\Foundation\DispatchEventsTrait; use Flarum\Group\GroupValidator; -use Flarum\Group\Event\Saving; +use Flarum\User\AssertPermissionTrait; +use Flarum\User\Exception\PermissionDeniedException; use Illuminate\Contracts\Events\Dispatcher; class EditGroupHandler diff --git a/src/Core/Command/ReadAllNotifications.php b/src/Notification/Command/ReadAllNotifications.php similarity index 93% rename from src/Core/Command/ReadAllNotifications.php rename to src/Notification/Command/ReadAllNotifications.php index d231153ce..d0ee62429 100644 --- a/src/Core/Command/ReadAllNotifications.php +++ b/src/Notification/Command/ReadAllNotifications.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Notification\Command; use Flarum\User\User; diff --git a/src/Core/Command/ReadAllNotificationsHandler.php b/src/Notification/Command/ReadAllNotificationsHandler.php similarity index 96% rename from src/Core/Command/ReadAllNotificationsHandler.php rename to src/Notification/Command/ReadAllNotificationsHandler.php index 7e2255fd5..4d99dfdf5 100644 --- a/src/Core/Command/ReadAllNotificationsHandler.php +++ b/src/Notification/Command/ReadAllNotificationsHandler.php @@ -9,10 +9,10 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Notification\Command; -use Flarum\User\AssertPermissionTrait; use Flarum\Notification\NotificationRepository; +use Flarum\User\AssertPermissionTrait; class ReadAllNotificationsHandler { diff --git a/src/Core/Command/ReadNotification.php b/src/Notification/Command/ReadNotification.php similarity index 95% rename from src/Core/Command/ReadNotification.php rename to src/Notification/Command/ReadNotification.php index f525299b7..93a139ea8 100644 --- a/src/Core/Command/ReadNotification.php +++ b/src/Notification/Command/ReadNotification.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Notification\Command; use Flarum\User\User; diff --git a/src/Core/Command/ReadNotificationHandler.php b/src/Notification/Command/ReadNotificationHandler.php similarity index 96% rename from src/Core/Command/ReadNotificationHandler.php rename to src/Notification/Command/ReadNotificationHandler.php index d8ed0a8fa..41da8e781 100644 --- a/src/Core/Command/ReadNotificationHandler.php +++ b/src/Notification/Command/ReadNotificationHandler.php @@ -9,10 +9,10 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Notification\Command; -use Flarum\User\AssertPermissionTrait; use Flarum\Notification\Notification; +use Flarum\User\AssertPermissionTrait; class ReadNotificationHandler { diff --git a/src/Core/Command/DeletePost.php b/src/Post/Command/DeletePost.php similarity index 97% rename from src/Core/Command/DeletePost.php rename to src/Post/Command/DeletePost.php index e2c2e897b..27d79dc09 100644 --- a/src/Core/Command/DeletePost.php +++ b/src/Post/Command/DeletePost.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Post\Command; use Flarum\User\User; diff --git a/src/Core/Command/DeletePostHandler.php b/src/Post/Command/DeletePostHandler.php similarity index 94% rename from src/Core/Command/DeletePostHandler.php rename to src/Post/Command/DeletePostHandler.php index 1e5301f2e..f21845ea4 100644 --- a/src/Core/Command/DeletePostHandler.php +++ b/src/Post/Command/DeletePostHandler.php @@ -9,13 +9,12 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Post\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\Exception\PermissionDeniedException; -use Flarum\Post\PostRepository; use Flarum\Foundation\DispatchEventsTrait; use Flarum\Post\Event\Deleting; +use Flarum\Post\PostRepository; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Events\Dispatcher; class DeletePostHandler diff --git a/src/Core/Command/EditPost.php b/src/Post/Command/EditPost.php similarity index 96% rename from src/Core/Command/EditPost.php rename to src/Post/Command/EditPost.php index 25390c890..270756d30 100644 --- a/src/Core/Command/EditPost.php +++ b/src/Post/Command/EditPost.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Post\Command; use Flarum\User\User; diff --git a/src/Core/Command/EditPostHandler.php b/src/Post/Command/EditPostHandler.php similarity index 98% rename from src/Core/Command/EditPostHandler.php rename to src/Post/Command/EditPostHandler.php index e2b093f9a..e4e3269e8 100644 --- a/src/Core/Command/EditPostHandler.php +++ b/src/Post/Command/EditPostHandler.php @@ -9,14 +9,14 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Post\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\Post\CommentPost; -use Flarum\Post\PostRepository; use Flarum\Foundation\DispatchEventsTrait; -use Flarum\Post\PostValidator; +use Flarum\Post\CommentPost; use Flarum\Post\Event\Saving; +use Flarum\Post\PostRepository; +use Flarum\Post\PostValidator; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Events\Dispatcher; class EditPostHandler diff --git a/src/Core/Command/PostReply.php b/src/Post/Command/PostReply.php similarity index 97% rename from src/Core/Command/PostReply.php rename to src/Post/Command/PostReply.php index 4877b3045..cc7575707 100644 --- a/src/Core/Command/PostReply.php +++ b/src/Post/Command/PostReply.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Post\Command; use Flarum\User\User; diff --git a/src/Core/Command/PostReplyHandler.php b/src/Post/Command/PostReplyHandler.php similarity index 99% rename from src/Core/Command/PostReplyHandler.php rename to src/Post/Command/PostReplyHandler.php index 2a8314a8e..519f515ec 100644 --- a/src/Core/Command/PostReplyHandler.php +++ b/src/Post/Command/PostReplyHandler.php @@ -9,16 +9,16 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\Post\Command; use DateTime; -use Flarum\User\AssertPermissionTrait; -use Flarum\Notification\NotificationSyncer; -use Flarum\Post\CommentPost; use Flarum\Discussion\DiscussionRepository; use Flarum\Foundation\DispatchEventsTrait; -use Flarum\Post\PostValidator; +use Flarum\Notification\NotificationSyncer; +use Flarum\Post\CommentPost; use Flarum\Post\Event\Saving; +use Flarum\Post\PostValidator; +use Flarum\User\AssertPermissionTrait; use Illuminate\Contracts\Events\Dispatcher; class PostReplyHandler diff --git a/src/Core/Command/ConfirmEmail.php b/src/User/Command/ConfirmEmail.php similarity index 94% rename from src/Core/Command/ConfirmEmail.php rename to src/User/Command/ConfirmEmail.php index 1b9f5ab0c..b07fd38a2 100644 --- a/src/Core/Command/ConfirmEmail.php +++ b/src/User/Command/ConfirmEmail.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; class ConfirmEmail { diff --git a/src/Core/Command/ConfirmEmailHandler.php b/src/User/Command/ConfirmEmailHandler.php similarity index 93% rename from src/Core/Command/ConfirmEmailHandler.php rename to src/User/Command/ConfirmEmailHandler.php index b657f1972..cef9f70b8 100644 --- a/src/Core/Command/ConfirmEmailHandler.php +++ b/src/User/Command/ConfirmEmailHandler.php @@ -9,16 +9,16 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; +use Flarum\Foundation\DispatchEventsTrait; use Flarum\User\EmailToken; use Flarum\User\UserRepository; -use Flarum\Foundation\DispatchEventsTrait; use Illuminate\Contracts\Events\Dispatcher; class ConfirmEmailHandler { - use Flarum\Foundation\DispatchEventsTrait; + use DispatchEventsTrait; /** * @var \Flarum\User\UserRepository diff --git a/src/Core/Command/DeleteAvatar.php b/src/User/Command/DeleteAvatar.php similarity index 96% rename from src/Core/Command/DeleteAvatar.php rename to src/User/Command/DeleteAvatar.php index a8f757c14..23593c245 100644 --- a/src/Core/Command/DeleteAvatar.php +++ b/src/User/Command/DeleteAvatar.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Flarum\User\User; diff --git a/src/Core/Command/DeleteAvatarHandler.php b/src/User/Command/DeleteAvatarHandler.php similarity index 95% rename from src/Core/Command/DeleteAvatarHandler.php rename to src/User/Command/DeleteAvatarHandler.php index 2dfe68efd..f75bea567 100644 --- a/src/Core/Command/DeleteAvatarHandler.php +++ b/src/User/Command/DeleteAvatarHandler.php @@ -9,13 +9,12 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\Exception\PermissionDeniedException; -use Flarum\User\UserRepository; -use Flarum\Foundation\DispatchEventsTrait; use Flarum\Event\AvatarWillBeDeleted; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\User\AssertPermissionTrait; +use Flarum\User\UserRepository; use Illuminate\Contracts\Events\Dispatcher; use League\Flysystem\FilesystemInterface; diff --git a/src/Core/Command/DeleteUser.php b/src/User/Command/DeleteUser.php similarity index 97% rename from src/Core/Command/DeleteUser.php rename to src/User/Command/DeleteUser.php index 2aa0f3edb..43bfd555c 100644 --- a/src/Core/Command/DeleteUser.php +++ b/src/User/Command/DeleteUser.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Flarum\User\User; diff --git a/src/Core/Command/DeleteUserHandler.php b/src/User/Command/DeleteUserHandler.php similarity index 97% rename from src/Core/Command/DeleteUserHandler.php rename to src/User/Command/DeleteUserHandler.php index e2f64e482..006d5e17b 100644 --- a/src/Core/Command/DeleteUserHandler.php +++ b/src/User/Command/DeleteUserHandler.php @@ -9,13 +9,13 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; +use Flarum\Foundation\DispatchEventsTrait; use Flarum\User\AssertPermissionTrait; +use Flarum\User\Event\Deleting; use Flarum\User\Exception\PermissionDeniedException; use Flarum\User\UserRepository; -use Flarum\Foundation\DispatchEventsTrait; -use Flarum\User\Event\Deleting; use Illuminate\Contracts\Events\Dispatcher; class DeleteUserHandler diff --git a/src/Core/Command/EditUser.php b/src/User/Command/EditUser.php similarity index 96% rename from src/Core/Command/EditUser.php rename to src/User/Command/EditUser.php index fa758483f..9ac9382de 100644 --- a/src/Core/Command/EditUser.php +++ b/src/User/Command/EditUser.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Flarum\User\User; diff --git a/src/Core/Command/EditUserHandler.php b/src/User/Command/EditUserHandler.php similarity index 99% rename from src/Core/Command/EditUserHandler.php rename to src/User/Command/EditUserHandler.php index cb2b2b725..a9df676c0 100644 --- a/src/Core/Command/EditUserHandler.php +++ b/src/User/Command/EditUserHandler.php @@ -9,15 +9,15 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\UserRepository; use Flarum\Foundation\DispatchEventsTrait; -use Flarum\User\User; -use Flarum\User\UserValidator; +use Flarum\User\AssertPermissionTrait; use Flarum\User\Event\GroupsChanged; use Flarum\User\Event\Saving; +use Flarum\User\User; +use Flarum\User\UserRepository; +use Flarum\User\UserValidator; use Illuminate\Contracts\Events\Dispatcher; class EditUserHandler diff --git a/src/Core/Command/RegisterUser.php b/src/User/Command/RegisterUser.php similarity index 95% rename from src/Core/Command/RegisterUser.php rename to src/User/Command/RegisterUser.php index 1d9a32b70..47494cf25 100644 --- a/src/Core/Command/RegisterUser.php +++ b/src/User/Command/RegisterUser.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Flarum\User\User; diff --git a/src/Core/Command/RegisterUserHandler.php b/src/User/Command/RegisterUserHandler.php similarity index 99% rename from src/Core/Command/RegisterUserHandler.php rename to src/User/Command/RegisterUserHandler.php index edbf35d65..cab155c22 100644 --- a/src/Core/Command/RegisterUserHandler.php +++ b/src/User/Command/RegisterUserHandler.php @@ -9,18 +9,18 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Exception; +use Flarum\Foundation\Application; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\Settings\SettingsRepositoryInterface; use Flarum\User\AssertPermissionTrait; use Flarum\User\AuthToken; +use Flarum\User\Event\Saving; use Flarum\User\Exception\PermissionDeniedException; -use Flarum\Foundation\DispatchEventsTrait; use Flarum\User\User; use Flarum\User\UserValidator; -use Flarum\User\Event\Saving; -use Flarum\Foundation\Application; -use Flarum\Settings\SettingsRepositoryInterface; use Illuminate\Contracts\Events\Dispatcher; use Illuminate\Contracts\Validation\Factory; use Illuminate\Contracts\Validation\ValidationException; diff --git a/src/Core/Command/RequestPasswordReset.php b/src/User/Command/RequestPasswordReset.php similarity index 94% rename from src/Core/Command/RequestPasswordReset.php rename to src/User/Command/RequestPasswordReset.php index 7a59942ae..fd997179d 100644 --- a/src/Core/Command/RequestPasswordReset.php +++ b/src/User/Command/RequestPasswordReset.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; class RequestPasswordReset { diff --git a/src/Core/Command/RequestPasswordResetHandler.php b/src/User/Command/RequestPasswordResetHandler.php similarity index 98% rename from src/Core/Command/RequestPasswordResetHandler.php rename to src/User/Command/RequestPasswordResetHandler.php index 4647bc004..ba464a698 100644 --- a/src/Core/Command/RequestPasswordResetHandler.php +++ b/src/User/Command/RequestPasswordResetHandler.php @@ -9,13 +9,12 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; -use Flarum\Core; -use Flarum\User\PasswordToken; -use Flarum\User\UserRepository; use Flarum\Forum\UrlGenerator; use Flarum\Settings\SettingsRepositoryInterface; +use Flarum\User\PasswordToken; +use Flarum\User\UserRepository; use Illuminate\Contracts\Mail\Mailer; use Illuminate\Contracts\Validation\Factory; use Illuminate\Contracts\Validation\ValidationException; diff --git a/src/Core/Command/UploadAvatar.php b/src/User/Command/UploadAvatar.php similarity index 97% rename from src/Core/Command/UploadAvatar.php rename to src/User/Command/UploadAvatar.php index ac34220e5..6a06cf852 100644 --- a/src/Core/Command/UploadAvatar.php +++ b/src/User/Command/UploadAvatar.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Flarum\User\User; use Psr\Http\Message\UploadedFileInterface; diff --git a/src/Core/Command/UploadAvatarHandler.php b/src/User/Command/UploadAvatarHandler.php similarity index 99% rename from src/Core/Command/UploadAvatarHandler.php rename to src/User/Command/UploadAvatarHandler.php index adcf76ee3..454373099 100644 --- a/src/Core/Command/UploadAvatarHandler.php +++ b/src/User/Command/UploadAvatarHandler.php @@ -9,15 +9,15 @@ * file that was distributed with this source code. */ -namespace Flarum\Core\Command; +namespace Flarum\User\Command; use Exception; -use Flarum\User\AssertPermissionTrait; -use Flarum\User\UserRepository; -use Flarum\Foundation\DispatchEventsTrait; -use Flarum\User\AvatarValidator; use Flarum\Event\AvatarWillBeSaved; use Flarum\Foundation\Application; +use Flarum\Foundation\DispatchEventsTrait; +use Flarum\User\AssertPermissionTrait; +use Flarum\User\UserRepository; +use Flarum\User\AvatarValidator; use Illuminate\Contracts\Events\Dispatcher; use Illuminate\Support\Str; use Intervention\Image\ImageManager; diff --git a/src/User/UserServiceProvider.php b/src/User/UserServiceProvider.php index 45a7e8a24..7c17943c6 100644 --- a/src/User/UserServiceProvider.php +++ b/src/User/UserServiceProvider.php @@ -41,15 +41,15 @@ class UserServiceProvider extends AbstractServiceProvider return $app->make('Illuminate\Contracts\Filesystem\Factory')->disk('flarum-avatars')->getDriver(); }; - $this->app->when('Flarum\Core\Command\UploadAvatarHandler') + $this->app->when('Flarum\User\Command\UploadAvatarHandler') ->needs('League\Flysystem\FilesystemInterface') ->give($avatarsFilesystem); - $this->app->when('Flarum\Core\Command\DeleteAvatarHandler') + $this->app->when('Flarum\User\Command\DeleteAvatarHandler') ->needs('League\Flysystem\FilesystemInterface') ->give($avatarsFilesystem); - $this->app->when('Flarum\Core\Command\RegisterUserHandler') + $this->app->when('Flarum\User\Command\RegisterUserHandler') ->needs('League\Flysystem\FilesystemInterface') ->give($avatarsFilesystem); }