This commit is contained in:
Bernhard Posselt 2014-05-01 23:04:08 +02:00
Родитель b78b3fe215
Коммит 8c58a41566
5 изменённых файлов: 4 добавлений и 7 удалений

Просмотреть файл

@ -81,7 +81,7 @@ $application->registerRoutes($this, array('routes' => array(
array('name' => 'feed_api#move', 'url' => '/api/v1-2/feeds/{feedId}/move', 'verb' => 'PUT'), // FIXME: POST would be more correct
array('name' => 'feed_api#rename', 'url' => '/api/v1-2/feeds/{feedId}/rename', 'verb' => 'PUT'), // FIXME: POST would be more correct
array('name' => 'feed_api#read', 'url' => '/api/v1-2/feeds/{feedId}/read', 'verb' => 'PUT'), // FIXME: POST would be more correct
array('name' => 'feed_api#update', 'url' => '/api/v1-2/update', 'verb' => 'GET'),
array('name' => 'feed_api#update', 'url' => '/api/v1-2/feeds/update', 'verb' => 'GET'),
// items
array('name' => 'item_api#index', 'url' => '/api/v1-2/items', 'verb' => 'GET'),

Просмотреть файл

@ -50,7 +50,6 @@ class ApiController extends Controller {
/**
* @NoCSRFRequired
* @API
*/
public function beforeUpdate() {
$this->updater->beforeUpdate();
@ -60,7 +59,6 @@ class ApiController extends Controller {
/**
* @NoCSRFRequired
* @API
*/
public function afterUpdate() {
$this->updater->afterUpdate();

Просмотреть файл

@ -201,7 +201,6 @@ class FeedApiController extends Controller {
/**
* @NoCSRFRequired
* @API
*/
public function update() {
$userId = $this->params('userId');

Просмотреть файл

@ -59,12 +59,12 @@ class ApiControllerTest extends ControllerTestUtility {
}
public function testBeforeUpdateAnnotations(){
$annotations = array('NoCSRFRequired', 'API');
$annotations = array('NoCSRFRequired');
$this->assertAnnotations($this->newsAPI, 'beforeUpdate', $annotations);
}
public function testAfterUpdateAnnotations(){
$annotations = array('NoCSRFRequired', 'API');
$annotations = array('NoCSRFRequired');
$this->assertAnnotations($this->newsAPI, 'afterUpdate', $annotations);
}

Просмотреть файл

@ -113,7 +113,7 @@ class FeedApiControllerTest extends ControllerTestUtility {
public function testUpdateAnnotations(){
$annotations = array('NoCSRFRequired', 'API');
$annotations = array('NoCSRFRequired');
$this->assertAnnotations($this->feedAPI, 'update', $annotations);
}