-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed a glitch generating swagger documentation
- Loading branch information
1 parent
77f5a8f
commit 0d5c77e
Showing
2 changed files
with
10 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
<?php | ||
/** | ||
* Created by PhpStorm. | ||
* User: Andre van Zuydam | ||
* Date: 2016/02/09 | ||
* Time: 02:02 PM | ||
* Purpose: Determine routing responses and data outputs based on the URL sent from the system | ||
* You are welcome to read and modify this code but it should not be broken, if you find something to improve it, send me an email with the patch | ||
* [email protected] | ||
*/ | ||
* Created by PhpStorm. | ||
* User: Andre van Zuydam | ||
* Date: 2016/02/09 | ||
* Time: 02:02 PM | ||
* Purpose: Determine routing responses and data outputs based on the URL sent from the system | ||
* You are welcome to read and modify this code but it should not be broken, if you find something to improve it, send me an email with the patch | ||
* [email protected] | ||
*/ | ||
namespace Tina4; | ||
|
||
class Routing | ||
|
@@ -273,7 +273,7 @@ function getSwagger($title = "Tina4", $description = "Swagger Documentation", $v | |
$method = strtolower($route["method"]); | ||
//echo $method; | ||
|
||
$reflection = new ReflectionFunction($route["function"]); | ||
$reflection = new \ReflectionFunction($route["function"]); | ||
$doc = $reflection->getDocComment(); | ||
preg_match_all('#@(.*?)\n#s', $doc, $annotations); | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters