Skip to content
This repository was archived by the owner on Sep 10, 2021. It is now read-only.

Commit 8a875b5

Browse files
author
Jamie Snape
committed
Fix legacy API help page
1 parent fec6bda commit 8a875b5

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

modules/api/library/APIEnabledNotification.php

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,20 @@
2424
*/
2525
class ApiEnabled_Notification extends MIDAS_Notification
2626
{
27+
/** @var string */
28+
public $moduleName = 'api';
29+
30+
/** @var array */
31+
public $_moduleComponents = array('Api');
32+
2733
/**
2834
* This function is for getting the web API methods defined in the API
2935
* component of the implementing class. To enable this add the following
3036
* line to your init function.
3137
*
3238
* $this->enableWebAPI();
39+
*
40+
* @return array
3341
*/
3442
public function getWebApiHelp()
3543
{
@@ -81,7 +89,11 @@ public function getWebApiHelp()
8189

8290
/**
8391
* Returns the actual method in your module corresponding to the requested method,
84-
* or false if the method doesn't exist.
92+
* or false if the method does not exist.
93+
*
94+
* @param array $params parameters
95+
*
96+
* @return false|array
8597
*/
8698
public function findWebApiMethod($params)
8799
{
@@ -97,6 +109,8 @@ public function findWebApiMethod($params)
97109
/**
98110
* Add to your init function to enable the web api for your module. This will
99111
* work provided you've created an ApiComponent.
112+
*
113+
* @param string $moduleName module name
100114
*/
101115
public function enableWebAPI($moduleName)
102116
{

0 commit comments

Comments
 (0)