Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed PHPCS build errors #14

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
/phpunit.xml
/vendor/
/build
/.idea
composer.lock
2 changes: 2 additions & 0 deletions phpcs.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@
<exclude name="MySource.Channels.IncludeSystem.NotIncludedCall"/>
</rule>
<rule ref="Generic">
<!-- This goes against PSR-2 -->
<exclude name="Generic.Classes.OpeningBraceSameLine.BraceOnNewLine"/>
<!--- we want spaces not tabs -->
<exclude name="Generic.WhiteSpace.DisallowSpaceIndent.SpacesUsed"/>
<!-- we want to use the allman braces style -->
Expand Down
2 changes: 1 addition & 1 deletion src/MiddlewareCors.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public function setLogger(LoggerInterface $logger = null)
* @param string $string String to log.
* @param array $logData Additional data to log.
*
* @return bool True if logged, false if no logger.
* @return boolean True if logged, false if no logger.
*/
public function addLog(string $string, array $logData = []) : bool
{
Expand Down
2 changes: 1 addition & 1 deletion src/MiddlewareCors/Preflight.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function __construct(callable $logger)
*
* @param string $string String to log.
*
* @return bool True if logged, false if no logger.
* @return boolean True if logged, false if no logger.
*/
final protected function addLog(string $string) : bool
{
Expand Down
2 changes: 1 addition & 1 deletion src/MiddlewareCors/Traits/Parse.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ trait Parse
*
* @param string $string String to log.
*
* @return bool True if logged, false if no logger.
* @return boolean True if logged, false if no logger.
*/
abstract protected function addLog(string $string) : bool;

Expand Down
10 changes: 5 additions & 5 deletions src/MiddlewareCors/ValidateSettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public function __invoke(string $name, $value, array $allowed)
* @param array $allowed Which items are allowed.
*
* @throws \InvalidArgumentException If the data is inaccurate/incorrect.
* @return bool True if validated, false if not
* @return boolean True if validated, false if not
*/
final protected function validateBool($value, array $allowed) : bool
{
Expand All @@ -75,7 +75,7 @@ final protected function validateBool($value, array $allowed) : bool
* @param array $allowed Which items are allowed.
*
* @throws \InvalidArgumentException If the data is inaccurate/incorrect.
* @return bool True if validated, false if not
* @return boolean True if validated, false if not
*/
final protected function validateString($value, array $allowed) : bool
{
Expand All @@ -95,7 +95,7 @@ final protected function validateString($value, array $allowed) : bool
* @param array $allowed Which items are allowed.
*
* @throws \InvalidArgumentException If the data is inaccurate/incorrect.
* @return bool True if validated, false if not
* @return boolean True if validated, false if not
*/
final protected function validateCallable($value, array $allowed) : bool
{
Expand All @@ -116,7 +116,7 @@ final protected function validateCallable($value, array $allowed) : bool
* @param array $allowed Which items are allowed.
*
* @throws \InvalidArgumentException If the data is inaccurate/incorrect.
* @return bool True if validated, false if not
* @return boolean True if validated, false if not
*/
final protected function validateInt(string $name, $value, array $allowed) : bool
{
Expand All @@ -141,7 +141,7 @@ final protected function validateInt(string $name, $value, array $allowed) : boo
* @param array $allowed Which items are allowed.
*
* @throws \InvalidArgumentException If the data is inaccurate/incorrect.
* @return bool True if validated, false if not
* @return boolean True if validated, false if not
*/
final protected function validateArray(string $name, $value, array $allowed) : bool
{
Expand Down