<?php

namespace Edge\QA\Tools\Analyzer;

use Edge\QA\OutputMode;

class SecurityChecker extends \Edge\QA\Tools\Tool
{
    public static $SETTINGS = array(
        'optionSeparator' => '=',
        'internalClass' => 'SensioLabs\Security\SecurityChecker',
        'outputMode' => OutputMode::RAW_CONSOLE_OUTPUT,
        'composer' => 'sensiolabs/security-checker',
    );

    public function __invoke()
    {
        $composerLock = getcwd() . "/composer.lock";
        foreach ($this->options->getAnalyzedDirs() as $escapedDir) {
            $dir = rtrim(trim($escapedDir, '"'), '/');
            $path = "{$dir}/composer.lock";
            if (file_exists($path)) {
                $composerLock = $path;
                break;
            }
        }
        $args = [
            'security:check',
            $composerLock,
        ];
        if (getenv('TRAVIS_COMMIT')) {
            $args['end-point'] = 'http://security.sensiolabs.org/check_lock';
        }
        return $args;
    }
}

<?php

namespace Edge\QA\Tools\Analyzer;

use Edge\QA\OutputMode;

class SecurityChecker extends \Edge\QA\Tools\Tool
{
    public static $SETTINGS = array(
        'optionSeparator' => '=',
        'internalClass' => 'SensioLabs\Security\SecurityChecker',
        'outputMode' => OutputMode::RAW_CONSOLE_OUTPUT,
        'composer' => 'sensiolabs/security-checker',
    );

    public function __invoke()
    {
        $composerLock = getcwd() . "/composer.lock";
        foreach ($this->options->getAnalyzedDirs() as $escapedDir) {
            $dir = rtrim(trim($escapedDir, '"'), '/');
            $path = "{$dir}/composer.lock";
            if (file_exists($path)) {
                $composerLock = $path;
                break;
            }
        }
        return [
            'security:check',
            $composerLock,
        ];
    }
}

Revert "Security-checker - fix tls issue at travis.ci"
Revert "Security-checker - fix tls issue at travis.ci"

This reverts commit 4c483c163b8e9c49eaca5cc34a9e74dc866b1a45.
