Skip to content

Commit 0d74a68

Browse files
author
vpaladiychuk
committed
MAGETWO-34995: Refactor controllers from the list (Part2)
1 parent 650303b commit 0d74a68

File tree

9 files changed

+20
-20
lines changed

9 files changed

+20
-20
lines changed

app/code/Magento/Sales/Controller/Adminhtml/Transactions/Fetch.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,13 @@
77
namespace Magento\Sales\Controller\Adminhtml\Transactions;
88

99
use Magento\Backend\App\Action;
10-
use Magento\Backend\Model\View\Result\Redirect;
1110

1211
class Fetch extends \Magento\Sales\Controller\Adminhtml\Transactions
1312
{
1413
/**
1514
* Fetch transaction details action
1615
*
17-
* @return Redirect
16+
* @return \Magento\Backend\Model\View\Result\Redirect
1817
*/
1918
public function execute()
2019
{
@@ -31,7 +30,7 @@ public function execute()
3130
}
3231

3332
/**
34-
* @return Redirect
33+
* @return \Magento\Backend\Model\View\Result\Redirect
3534
*/
3635
public function getDefaultRedirect()
3736
{

app/code/Magento/Shipping/Controller/Adminhtml/Order/Shipment/Email.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ protected function _isAllowed()
4545
/**
4646
* Send email with shipment data to customer
4747
*
48-
* @return \Magento\Framework\Controller\Result\Redirect
48+
* @return \Magento\Backend\Model\View\Result\Redirect
4949
*/
5050
public function execute()
5151
{
@@ -66,7 +66,7 @@ public function execute()
6666
/**
6767
* @inheritdoc
6868
*
69-
* @return \Magento\Framework\Controller\Result\Redirect
69+
* @return \Magento\Backend\Model\View\Result\Redirect
7070
*/
7171
public function getDefaultRedirect()
7272
{

app/code/Magento/Shipping/Test/Unit/Controller/Adminhtml/Order/Shipment/EmailTest.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,12 @@ class EmailTest extends \PHPUnit_Framework_TestCase
6464
protected $helper;
6565

6666
/**
67-
* @var \Magento\Framework\Controller\Result\RedirectFactory|\PHPUnit_Framework_MockObject_MockObject
67+
* @var \Magento\Backend\Model\View\Result\RedirectFactory|\PHPUnit_Framework_MockObject_MockObject
6868
*/
6969
protected $resultRedirectFactory;
7070

7171
/**
72-
* @var \Magento\Framework\Controller\Result\Redirect|\PHPUnit_Framework_MockObject_MockObject
72+
* @var \Magento\Backend\Model\View\Result\Redirect|\PHPUnit_Framework_MockObject_MockObject
7373
*/
7474
protected $resultRedirect;
7575

@@ -140,9 +140,9 @@ public function setUp()
140140
$this->session = $this->getMock('Magento\Backend\Model\Session', ['setIsUrlNotice'], [], '', false);
141141
$this->actionFlag = $this->getMock('Magento\Framework\App\ActionFlag', ['get'], [], '', false);
142142
$this->helper = $this->getMock('\Magento\Backend\Helper\Data', ['getUrl'], [], '', false);
143-
$this->resultRedirect = $this->getMock('Magento\Framework\Controller\Result\Redirect', [], [], '', false);
143+
$this->resultRedirect = $this->getMock('Magento\Backend\Model\View\Result\Redirect', [], [], '', false);
144144
$this->resultRedirectFactory = $this->getMock(
145-
'Magento\Framework\Controller\Result\RedirectFactory',
145+
'Magento\Backend\Model\View\Result\RedirectFactory',
146146
['create'],
147147
[],
148148
'',

app/code/Magento/Tax/Controller/Adminhtml/Rate/Delete.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class Delete extends \Magento\Tax\Controller\Adminhtml\Rate
1313
/**
1414
* Delete Rate and Data
1515
*
16-
* @return \Magento\Framework\Controller\Result\Redirect|void
16+
* @return \Magento\Backend\Model\View\Result\Redirect|void
1717
*/
1818
public function execute()
1919
{
@@ -38,7 +38,7 @@ public function execute()
3838
/**
3939
* @inheritdoc
4040
*
41-
* @return \Magento\Framework\Controller\Result\Redirect
41+
* @return \Magento\Backend\Model\View\Result\Redirect
4242
*/
4343
public function getDefaultRedirect()
4444
{

app/code/Magento/Tax/Controller/Adminhtml/Rule/Delete.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,10 @@
66
*/
77
namespace Magento\Tax\Controller\Adminhtml\Rule;
88

9-
109
class Delete extends \Magento\Tax\Controller\Adminhtml\Rule
1110
{
1211
/**
13-
* @return \Magento\Framework\Controller\Result\Redirect|void
12+
* @return \Magento\Backend\Model\View\Result\Redirect
1413
*/
1514
public function execute()
1615
{
@@ -31,7 +30,7 @@ public function execute()
3130
/**
3231
* @inheritdoc
3332
*
34-
* @return \Magento\Framework\Controller\Result\Redirect
33+
* @return \Magento\Backend\Model\View\Result\Redirect
3534
*/
3635
public function getDefaultRedirect()
3736
{

app/code/Magento/Theme/Controller/Adminhtml/System/Design/Theme/Delete.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ class Delete extends \Magento\Theme\Controller\Adminhtml\System\Design\Theme
1111
/**
1212
* Delete action
1313
*
14-
* @return void
14+
* @return \Magento\Backend\Model\View\Result\Redirect
1515
*/
1616
public function execute()
1717
{
@@ -36,7 +36,7 @@ public function execute()
3636
/**
3737
* @inheritdoc
3838
*
39-
* @return \Magento\Framework\Controller\Result\Redirect
39+
* @return \Magento\Backend\Model\View\Result\Redirect
4040
*/
4141
public function getDefaultRedirect()
4242
{

app/code/Magento/User/Controller/Adminhtml/User/Role/Delete.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ class Delete extends \Magento\User\Controller\Adminhtml\User\Role
1111
/**
1212
* Remove role action
1313
*
14-
* @return void
14+
* @return \Magento\Backend\Model\View\Result\Redirect|void
1515
*/
1616
public function execute()
1717
{
@@ -33,7 +33,7 @@ public function execute()
3333
/**
3434
* @inheritdoc
3535
*
36-
* @return \Magento\Framework\Controller\Result\Redirect
36+
* @return \Magento\Backend\Model\View\Result\Redirect
3737
*/
3838
public function getDefaultRedirect()
3939
{

app/code/Magento/User/Controller/Adminhtml/User/Role/SaveRole.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ protected function _deleteUserFromRole($userId, $roleId)
5252
/**
5353
* Role form submit action to save or create new role
5454
*
55-
* @return \Magento\Framework\Controller\Result\Redirect|void
55+
* @return \Magento\Backend\Model\View\Result\Redirect
5656
*/
5757
public function execute()
5858
{
@@ -104,7 +104,7 @@ public function execute()
104104
/**
105105
* @inheritdoc
106106
*
107-
* @return \Magento\Framework\Controller\Result\Redirect
107+
* @return \Magento\Backend\Model\View\Result\Redirect
108108
*/
109109
public function getDefaultRedirect()
110110
{

app/code/Magento/Wishlist/Controller/Index/Fromcart.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ public function __construct(
3030
}
3131

3232
/**
33+
* Add cart item to wishlist and remove from cart
34+
*
3335
* @return \Magento\Framework\Controller\Result\Redirect
3436
* @throws NotFoundException
3537
* @throws \Magento\Framework\Exception\LocalizedException

0 commit comments

Comments
 (0)