mediawiki/extensions/DonationInterface: main (log #1411625)

sourcepatches

This run took 37 seconds.

$ date
--- stdout ---
Tue Jul  2 01:27:01 UTC 2024

--- end ---
$ git clone file:///srv/git/mediawiki-extensions-DonationInterface.git repo --depth=1 -b master
--- stderr ---
Cloning into 'repo'...
--- stdout ---

--- end ---
$ git config user.name libraryupgrader
--- stdout ---

--- end ---
$ git config user.email tools.libraryupgrader@tools.wmflabs.org
--- stdout ---

--- end ---
$ git submodule update --init
--- stdout ---

--- end ---
$ grr init
--- stdout ---
Installed commit-msg hook.

--- end ---
$ git show-ref refs/heads/master
--- stdout ---
aac0b2d63f2f02405f29159fb931eb8448af4d53 refs/heads/master

--- end ---
$ /usr/bin/npm audit --json
--- stdout ---
{
  "auditReportVersion": 2,
  "vulnerabilities": {
    "braces": {
      "name": "braces",
      "severity": "high",
      "isDirect": false,
      "via": [
        {
          "source": 1097496,
          "name": "braces",
          "dependency": "braces",
          "title": "Uncontrolled resource consumption in braces",
          "url": "https://github.com/advisories/GHSA-grv7-fg5c-xmjg",
          "severity": "high",
          "cwe": [
            "CWE-1050"
          ],
          "cvss": {
            "score": 7.5,
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
          },
          "range": "<3.0.3"
        }
      ],
      "effects": [],
      "range": "<3.0.3",
      "nodes": [
        "node_modules/braces"
      ],
      "fixAvailable": true
    }
  },
  "metadata": {
    "vulnerabilities": {
      "info": 0,
      "low": 0,
      "moderate": 0,
      "high": 1,
      "critical": 0,
      "total": 1
    },
    "dependencies": {
      "prod": 1,
      "dev": 477,
      "optional": 0,
      "peer": 10,
      "peerOptional": 0,
      "total": 477
    }
  }
}

--- end ---
$ /usr/bin/composer install
--- stderr ---
No composer.lock file present. Updating dependencies to latest instead of installing from lock file. See https://getcomposer.org/install for more information.
Loading composer repositories with package information
                                                      Updating dependencies
Lock file operations: 65 installs, 0 updates, 0 removals
  - Locking addshore/psr-6-mediawiki-bagostuff-adapter (0.1)
  - Locking amzn/login-and-pay-with-amazon-sdk-php (2.5.0)
  - Locking clio/clio (0.1.8)
  - Locking coderkungfu/php-queue (1.0.1)
  - Locking composer/ca-bundle (1.5.0)
  - Locking composer/pcre (3.1.4)
  - Locking composer/semver (3.4.0)
  - Locking composer/spdx-licenses (1.5.8)
  - Locking composer/xdebug-handler (3.0.5)
  - Locking corneltek/getoptionkit (2.7.2)
  - Locking dealerdirect/phpcodesniffer-composer-installer (v1.0.0)
  - Locking doctrine/deprecations (1.1.3)
  - Locking felixfbecker/advanced-json-rpc (v3.2.1)
  - Locking geoip2/geoip2 (v2.13.0)
  - Locking maxmind-db/reader (v1.11.1)
  - Locking maxmind/minfraud (v1.23.0)
  - Locking maxmind/web-service-common (v0.9.0)
  - Locking mediawiki/mediawiki-codesniffer (v43.0.0)
  - Locking mediawiki/mediawiki-phan-config (0.14.0)
  - Locking mediawiki/minus-x (1.1.3)
  - Locking mediawiki/phan-taint-check-plugin (6.0.0)
  - Locking microsoft/tolerant-php-parser (v0.1.2)
  - Locking monolog/monolog (2.9.3)
  - Locking neitanod/forceutf8 (v2.0.4)
  - Locking netresearch/jsonmapper (v4.4.1)
  - Locking phan/phan (5.4.3)
  - Locking php-parallel-lint/php-console-color (v1.0.1)
  - Locking php-parallel-lint/php-console-highlighter (v1.0.0)
  - Locking php-parallel-lint/php-parallel-lint (v1.4.0)
  - Locking phpcsstandards/phpcsextra (1.1.2)
  - Locking phpcsstandards/phpcsutils (1.0.9)
  - Locking phpdocumentor/reflection-common (2.2.0)
  - Locking phpdocumentor/reflection-docblock (5.4.1)
  - Locking phpdocumentor/type-resolver (1.8.2)
  - Locking phpmailer/phpmailer (v6.9.1)
  - Locking phpstan/phpdoc-parser (1.29.1)
  - Locking predis/predis (v1.1.10)
  - Locking psr/cache (1.0.1)
  - Locking psr/container (1.1.2)
  - Locking psr/log (1.1.4)
  - Locking respect/stringifier (0.2.0)
  - Locking respect/validation (2.2.4)
  - Locking sabre/event (5.1.4)
  - Locking squizlabs/php_codesniffer (3.8.1)
  - Locking symfony/console (v5.4.41)
  - Locking symfony/deprecation-contracts (v2.5.3)
  - Locking symfony/http-foundation (v2.8.52)
  - Locking symfony/polyfill-ctype (v1.30.0)
  - Locking symfony/polyfill-intl-grapheme (v1.30.0)
  - Locking symfony/polyfill-intl-normalizer (v1.30.0)
  - Locking symfony/polyfill-mbstring (v1.30.0)
  - Locking symfony/polyfill-php54 (v1.20.0)
  - Locking symfony/polyfill-php55 (v1.20.0)
  - Locking symfony/polyfill-php73 (v1.30.0)
  - Locking symfony/polyfill-php80 (v1.30.0)
  - Locking symfony/service-contracts (v2.5.3)
  - Locking symfony/string (v5.4.41)
  - Locking symfony/yaml (v5.4.40)
  - Locking tysonandre/var_representation_polyfill (0.1.3)
  - Locking webmozart/assert (1.11.0)
  - Locking whichbrowser/parser (v2.1.8)
  - Locking wikimedia/remex-html (4.1.0)
  - Locking wikimedia/smash-pig (v0.8.10.10)
  - Locking wikimedia/testing-access-wrapper (1.0.0)
  - Locking wikimedia/utfnormal (3.0.2)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 65 installs, 0 updates, 0 removals
  - Syncing amzn/login-and-pay-with-amazon-sdk-php (2.5.0) into cache
    0 [>---------------------------]    0 [->--------------------------]
  - Installing squizlabs/php_codesniffer (3.8.1): Extracting archive
  - Installing dealerdirect/phpcodesniffer-composer-installer (v1.0.0): Extracting archive
  - Installing psr/cache (1.0.1): Extracting archive
  - Installing addshore/psr-6-mediawiki-bagostuff-adapter (0.1): Extracting archive
  - Installing clio/clio (0.1.8): Extracting archive
  - Installing composer/pcre (3.1.4): Extracting archive
  - Installing maxmind-db/reader (v1.11.1): Extracting archive
  - Installing symfony/polyfill-mbstring (v1.30.0): Extracting archive
  - Installing respect/stringifier (0.2.0): Extracting archive
  - Installing respect/validation (2.2.4): Extracting archive
  - Installing composer/ca-bundle (1.5.0): Extracting archive
  - Installing maxmind/web-service-common (v0.9.0): Extracting archive
  - Installing geoip2/geoip2 (v2.13.0): Extracting archive
  - Installing maxmind/minfraud (v1.23.0): Extracting archive
  - Installing symfony/polyfill-php80 (v1.30.0): Extracting archive
  - Installing phpcsstandards/phpcsutils (1.0.9): Extracting archive
  - Installing phpcsstandards/phpcsextra (1.1.2): Extracting archive
  - Installing composer/spdx-licenses (1.5.8): Extracting archive
  - Installing composer/semver (3.4.0): Extracting archive
  - Installing mediawiki/mediawiki-codesniffer (v43.0.0): Extracting archive
  - Installing tysonandre/var_representation_polyfill (0.1.3): Extracting archive
  - Installing symfony/polyfill-intl-normalizer (v1.30.0): Extracting archive
  - Installing symfony/polyfill-intl-grapheme (v1.30.0): Extracting archive
  - Installing symfony/polyfill-ctype (v1.30.0): Extracting archive
  - Installing symfony/string (v5.4.41): Extracting archive
  - Installing symfony/deprecation-contracts (v2.5.3): Extracting archive
  - Installing psr/container (1.1.2): Extracting archive
  - Installing symfony/service-contracts (v2.5.3): Extracting archive
  - Installing symfony/polyfill-php73 (v1.30.0): Extracting archive
  - Installing symfony/console (v5.4.41): Extracting archive
  - Installing sabre/event (5.1.4): Extracting archive
  - Installing netresearch/jsonmapper (v4.4.1): Extracting archive
  - Installing microsoft/tolerant-php-parser (v0.1.2): Extracting archive
  - Installing webmozart/assert (1.11.0): Extracting archive
  - Installing phpstan/phpdoc-parser (1.29.1): Extracting archive
  - Installing phpdocumentor/reflection-common (2.2.0): Extracting archive
  - Installing doctrine/deprecations (1.1.3): Extracting archive
  - Installing phpdocumentor/type-resolver (1.8.2): Extracting archive
  - Installing phpdocumentor/reflection-docblock (5.4.1): Extracting archive
  - Installing felixfbecker/advanced-json-rpc (v3.2.1): Extracting archive
  - Installing psr/log (1.1.4): Extracting archive
  - Installing composer/xdebug-handler (3.0.5): Extracting archive
  - Installing phan/phan (5.4.3): Extracting archive
  - Installing mediawiki/phan-taint-check-plugin (6.0.0): Extracting archive
  - Installing mediawiki/mediawiki-phan-config (0.14.0): Extracting archive
  - Installing mediawiki/minus-x (1.1.3): Extracting archive
  - Installing monolog/monolog (2.9.3): Extracting archive
  - Installing neitanod/forceutf8 (v2.0.4): Extracting archive
  - Installing php-parallel-lint/php-console-color (v1.0.1): Extracting archive
  - Installing php-parallel-lint/php-console-highlighter (v1.0.0): Extracting archive
  - Installing php-parallel-lint/php-parallel-lint (v1.4.0): Extracting archive
  - Installing symfony/polyfill-php54 (v1.20.0)
  - Installing symfony/polyfill-php55 (v1.20.0)
  - Installing whichbrowser/parser (v2.1.8): Extracting archive
  - Installing wikimedia/utfnormal (3.0.2): Extracting archive
  - Installing wikimedia/remex-html (4.1.0): Extracting archive
  - Installing symfony/yaml (v5.4.40): Extracting archive
  - Installing symfony/http-foundation (v2.8.52): Extracting archive
  - Installing predis/predis (v1.1.10): Extracting archive
  - Installing phpmailer/phpmailer (v6.9.1): Extracting archive
  - Installing corneltek/getoptionkit (2.7.2): Extracting archive
  - Installing coderkungfu/php-queue (1.0.1): Extracting archive
  - Installing amzn/login-and-pay-with-amazon-sdk-php (2.5.0): Cloning 0c923fe992 from cache
  - Installing wikimedia/smash-pig (v0.8.10.10): Extracting archive
  - Installing wikimedia/testing-access-wrapper (1.0.0): Extracting archive
  0/60 [>---------------------------]   0%
 20/60 [=========>------------------]  33%
 30/60 [==============>-------------]  50%
 40/60 [==================>---------]  66%
 48/60 [======================>-----]  80%
 59/60 [===========================>]  98%
 60/60 [============================] 100%
33 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating optimized autoload files
Class SmashPig\PaymentProviders\Fundraiseup\Tests\AuditTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Fundraiseup/Tests/phpunit/AuditTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\Manual\TestCreatePayment located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/manual/TestCreatePayment.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\IdealStatusProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/IdealStatusProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\HostedCheckoutProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/HostedCheckoutProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\ApiTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/ApiTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\AuditTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/AuditTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\AuthenticatorTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/AuthenticatorTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\BankPaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/BankPaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\PaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/PaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Ingenico\Tests\TokenizeRecurringJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Ingenico/Tests/phpunit/TokenizeRecurringJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Amazon\Tests\RecordPaymentsJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Amazon/Tests/phpunit/RecordPaymentsJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Amazon\Tests\NormalizeTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Amazon/Tests/phpunit/NormalizeTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Amazon\Tests\ActionsTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Amazon/Tests/phpunit/ActionsTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Amazon\Tests\ApiTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Amazon/Tests/phpunit/ApiTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Amazon\Tests\AuditTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Amazon/Tests/phpunit/AuditTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\CaptureJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/CaptureJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\RestResponseValidatorTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/RestResponseValidatorTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\RequeueMessageTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/RequeueMessageTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\PaymentCaptureActionTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/PaymentCaptureActionTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\RefundInitiatedActionTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/RefundInitiatedActionTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\RecurringPaymentTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/RecurringPaymentTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\ReferenceDataTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/ReferenceDataTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\ApiTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/ApiTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\AutoRescueActionTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/AutoRescueActionTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\ChargebackInitiatedActionTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/ChargebackInitiatedActionTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\ReportAvailableTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/ReportAvailableTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\AuditTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/AuditTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Test\RecordCaptureJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/RecordCaptureJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\TokenizeRecurringJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/TokenizeRecurringJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\Tests\CaptureResponseActionTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/Tests/phpunit/CaptureResponseActionTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\NotificationRequest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\NotificationRequestItem located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\anyType2anyTypeMap located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\entry located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\sendNotification located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\sendNotificationResponse located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\Amount located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\ServiceException located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\Error located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\Type located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Adyen\WSDL\ClassMap located in ./vendor/wikimedia/smash-pig/PaymentProviders/Adyen/WSDL/Notification.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Gravy\ResponseMapper located in ./vendor/wikimedia/smash-pig/PaymentProviders/Gravy/Mapper/ResponseMapper.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Gravy\RequestMapper located in ./vendor/wikimedia/smash-pig/PaymentProviders/Gravy/Mapper/RequestMapper.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Gravy\Validator located in ./vendor/wikimedia/smash-pig/PaymentProviders/Gravy/Validator/Validator.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Tests\PaidMessageJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/PaidMessageJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Tests\RestResponseValidatorTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/RestResponseValidatorTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Tests\RejectedMessageJobTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/RejectedMessageJobTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Tests\SignatureCalculatorTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/SignatureCalculatorTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Tests\ApiTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/ApiTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Test\AuditTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/AuditTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\dlocal\Tests\CardPaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/dlocal/Tests/phpunit/CardPaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\PayPal\Tests\CaptureIncomingMessageTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/PayPal/Tests/phpunit/CaptureIncomingMessageTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\PayPal\Tests\PaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/PayPal/Tests/phpunit/PaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Braintree\Tests\SignatureValidatorTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Braintree/Tests/phpunit/SignatureValidatorTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Braintree\Tests\PayPalPaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Braintree/Tests/phpunit/PayPalPaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Braintree\Tests\VenmoPaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Braintree/Tests/phpunit/VenmoPaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Braintree\Tests\ApiTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Braintree/Tests/phpunit/ApiTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Braintree\Test\AuditTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Braintree/Tests/phpunit/AuditTest.php does not comply with psr-4 autoloading standard. Skipping.
Class SmashPig\PaymentProviders\Braintree\Tests\PaymentProviderTest located in ./vendor/wikimedia/smash-pig/PaymentProviders/Braintree/Tests/phpunit/PaymentProviderTest.php does not comply with psr-4 autoloading standard. Skipping.
23 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
--- stdout ---
PHP CodeSniffer Config installed_paths set to ../../mediawiki/mediawiki-codesniffer,../../phpcsstandards/phpcsextra,../../phpcsstandards/phpcsutils

--- end ---
Upgrading n:eslint-config-wikimedia from 0.27.0 -> 0.28.2
Upgrading n:grunt-banana-checker from 0.11.1 -> 0.13.0
Upgrading n:grunt-stylelint from 0.19.0 -> 0.20.1
Upgrading n:stylelint-config-wikimedia from 0.16.1 -> 0.17.2
$ /usr/bin/npm install
--- stdout ---

added 458 packages, and audited 459 packages in 7s

91 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

--- end ---
$ package-lock-lint package-lock.json
--- stdout ---
Checking package-lock.json

--- end ---
$ /usr/bin/npm install grunt-eslint@24.3.0 --save-exact
--- stdout ---

up to date, audited 459 packages in 926ms

91 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

--- end ---
$ package-lock-lint package-lock.json
--- stdout ---
Checking package-lock.json

--- end ---
$ ./node_modules/.bin/eslint braintree_gateway/forms/braintree.js modules/js/ext.donationInterface.employerExplain.js modules/js/ext.donationInterface.monthlyConvert.js modules/js/ext.donationInterface.forms.js modules/js/ext.donationInterface.monthlyConvertButtonFlip.js amazon_gateway/amazon.js paypal_ec_gateway/forms/js/paypal.js modules/js/ext.donationInterface.monthlyConvert_011.js ./extension.json ./package.json modules/js/ext.donationInterface.jaVariant02.js ingenico_gateway/forms/js/ingenico.js modules/js/ext.donationInterface.validation.js modules/js/ext.donationInterface.recurUpgrade.js modules/js/skinOverride.js dlocal_gateway/forms/dlocal.js modules/js/ext.donationInterface.alwaysRedirect.js modules/js/ext.donationInterface.employerExplainAlt.js ./package-lock.json modules/js/ext.donationInterface.employerAutoComplete.js modules/iframe.liberator.js modules/js/ext.donationInterface.monthlyConvertMultiplier.js modules/js/ext.donationInterface.monthlyConvert_010.js ./Gruntfile.js modules/validate_input.js modules/js/ext.donationInterface.emailPreferences.js ./composer.json adyen_gateway/forms/adyen.js modules/js/ext.donationInterface.errorLog.js modules/js/ext.donationInterface.monthlyConvert_003.js --fix
--- stdout ---

/src/repo/adyen_gateway/forms/adyen.js
   24:1   warning  Missing JSDoc @return type                   jsdoc/require-returns-type
   78:23  warning  ES2015 'Promise' class is forbidden          es-x/no-promise
  160:23  warning  ES2015 'Promise' class is forbidden          es-x/no-promise
  220:34  warning  ES2015 'Promise' class is forbidden          es-x/no-promise
  224:14  warning  ES2015 'Promise' class is forbidden          es-x/no-promise
  234:1   warning  Missing JSDoc @param "extraData" type        jsdoc/require-param-type
  235:1   warning  Missing JSDoc @param "billingContact" type   jsdoc/require-param-type
  236:1   warning  Missing JSDoc @param "shippingContact" type  jsdoc/require-param-type
  343:22  warning  ES2015 'Promise' class is forbidden          es-x/no-promise
  422:6   error    ES2015 'Object.assign' method is forbidden   es-x/no-object-assign
  551:4   error    ES2015 'Object.assign' method is forbidden   es-x/no-object-assign
  648:4   warning  ES2015 'Promise' class is forbidden          es-x/no-promise
  675:4   warning  ES2015 'Promise' class is forbidden          es-x/no-promise

/src/repo/amazon_gateway/amazon.js
   14:23  warning  Use a regular expression literal instead of the 'RegExp' constructor  prefer-regex-literals
  268:8   warning  Selector extensions are not allowed                                   no-jquery/no-sizzle

/src/repo/modules/iframe.liberator.js
  1:10  warning  'self' is already defined as a built-in global variable  no-redeclare

/src/repo/modules/js/ext.donationInterface.forms.js
    4:1   warning  Missing JSDoc @param "$" type               jsdoc/require-param-type
    5:1   warning  Missing JSDoc @param "mw" type              jsdoc/require-param-type
   74:25  warning  Selector extensions are not allowed         no-jquery/no-sizzle
  105:1   warning  The type 'result' is undefined              jsdoc/no-undefined-types
  162:4   error    ES2015 'Object.assign' method is forbidden  es-x/no-object-assign
  249:8   warning  Selector extensions are not allowed         no-jquery/no-sizzle

/src/repo/modules/js/ext.donationInterface.jaVariant02.js
  8:1  warning  Missing JSDoc @param "mw" type  jsdoc/require-param-type
  9:1  warning  Missing JSDoc @param "$" type   jsdoc/require-param-type

/src/repo/modules/js/ext.donationInterface.monthlyConvert.js
  26:49  warning  'currency' is already declared in the upper scope on line 3 column 3  no-shadow
  34:39  warning  'currency' is already declared in the upper scope on line 3 column 3  no-shadow

/src/repo/modules/js/ext.donationInterface.validation.js
   7:1   warning  Missing JSDoc @param "$" type                                    jsdoc/require-param-type
   8:1   warning  Missing JSDoc @param "mw" type                                   jsdoc/require-param-type
  40:35  warning  'i' is already declared in the upper scope on line 39 column 45  no-shadow

/src/repo/modules/validate_input.js
    1:1   warning  Missing JSDoc @return declaration                                                    jsdoc/require-returns
  106:27  warning  'value' is already declared in the upper scope on line 83 column 6                   no-shadow
  108:14  warning  All possible message keys should be documented. See https://w.wiki/4r9a for details  mediawiki/msg-doc
  114:32  warning  'i' is already declared in the upper scope on line 86 column 3                       no-shadow

✖ 33 problems (3 errors, 30 warnings)


--- end ---
$ ./node_modules/.bin/eslint braintree_gateway/forms/braintree.js modules/js/ext.donationInterface.employerExplain.js modules/js/ext.donationInterface.monthlyConvert.js modules/js/ext.donationInterface.forms.js modules/js/ext.donationInterface.monthlyConvertButtonFlip.js amazon_gateway/amazon.js paypal_ec_gateway/forms/js/paypal.js modules/js/ext.donationInterface.monthlyConvert_011.js ./extension.json ./package.json modules/js/ext.donationInterface.jaVariant02.js ingenico_gateway/forms/js/ingenico.js modules/js/ext.donationInterface.validation.js modules/js/ext.donationInterface.recurUpgrade.js modules/js/skinOverride.js dlocal_gateway/forms/dlocal.js modules/js/ext.donationInterface.alwaysRedirect.js modules/js/ext.donationInterface.employerExplainAlt.js ./package-lock.json modules/js/ext.donationInterface.employerAutoComplete.js modules/iframe.liberator.js modules/js/ext.donationInterface.monthlyConvertMultiplier.js modules/js/ext.donationInterface.monthlyConvert_010.js ./Gruntfile.js modules/validate_input.js modules/js/ext.donationInterface.emailPreferences.js ./composer.json adyen_gateway/forms/adyen.js modules/js/ext.donationInterface.errorLog.js modules/js/ext.donationInterface.monthlyConvert_003.js -f json
--- stdout ---
[{"filePath":"/src/repo/Gruntfile.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/adyen_gateway/forms/adyen.js","messages":[{"ruleId":"jsdoc/require-returns-type","severity":1,"message":"Missing JSDoc @return type.","line":24,"column":1,"nodeType":"Block","endLine":24,"endColumn":1},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":78,"column":23,"nodeType":"Identifier","messageId":"forbidden","endLine":78,"endColumn":30},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":160,"column":23,"nodeType":"Identifier","messageId":"forbidden","endLine":160,"endColumn":30},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":220,"column":34,"nodeType":"Identifier","messageId":"forbidden","endLine":220,"endColumn":41},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":224,"column":14,"nodeType":"Identifier","messageId":"forbidden","endLine":224,"endColumn":21},{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"extraData\" type.","line":234,"column":1,"nodeType":"Block","endLine":234,"endColumn":1},{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"billingContact\" type.","line":235,"column":1,"nodeType":"Block","endLine":235,"endColumn":1},{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"shippingContact\" type.","line":236,"column":1,"nodeType":"Block","endLine":236,"endColumn":1},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":343,"column":22,"nodeType":"Identifier","messageId":"forbidden","endLine":343,"endColumn":29},{"ruleId":"es-x/no-object-assign","severity":2,"message":"ES2015 'Object.assign' method is forbidden.","line":422,"column":6,"nodeType":"MemberExpression","messageId":"forbidden","endLine":422,"endColumn":19},{"ruleId":"es-x/no-object-assign","severity":2,"message":"ES2015 'Object.assign' method is forbidden.","line":551,"column":4,"nodeType":"MemberExpression","messageId":"forbidden","endLine":551,"endColumn":17},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":648,"column":4,"nodeType":"Identifier","messageId":"forbidden","endLine":648,"endColumn":11},{"ruleId":"es-x/no-promise","severity":1,"message":"ES2015 'Promise' class is forbidden.","line":675,"column":4,"nodeType":"Identifier","messageId":"forbidden","endLine":675,"endColumn":11}],"suppressedMessages":[],"errorCount":2,"fatalErrorCount":0,"warningCount":11,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/* global AdyenCheckout, Promise */\n( function ( $, mw ) {\n\t// promise objects are for Apple Pay - see comments below\n\tvar checkout, onSubmit, authPromise, submitPromise,\n\t\tconfigFromServer = mw.config.get( 'adyenConfiguration' ),\n\t\tpayment_method = $( '#payment_method' ).val(),\n\t\tonBrandSubmethod = '',\n\t\tcountry = $( '#country' ).val(),\n\t\tlanguage = $( '#language' ).val(),\n\t\t// This is the old-style Google Pay integration type currently active on\n\t\t// our account. Older versions of the Adyen JS SDK treated the 'googlepay'\n\t\t// component type as the old GPay integration, but for newer versions of\n\t\t// the GPay SDK we need to explicitly specify 'paywithgoogle' to get tokens\n\t\t// that work with the old-style integration. At some point we should upgrade\n\t\t// to the new interaction, but that will require coordinating an update to\n\t\t// this constant with an update to our account.\n\t\tGOOGLEPAY_COMPONENT_TYPE = 'paywithgoogle';\n\n\t/**\n\t * Get extra configuration values for specific payment types\n\t *\n\t * @param {string} type Adyen-side name of component type\n\t * @param {Object} checkoutConfig The config object used to instantiate the Adyen Checkout object\n\t * @return Object\n\t */\n\tfunction getComponentConfig( type, checkoutConfig ) {\n\t\tvar config = {};\n\t\tswitch ( type ) {\n\t\t\tcase 'card':\n\t\t\t\t// Note: Debug messages are only sent and logged server-side if\n\t\t\t\t// $wgDonationInterfaceLogDebug (or $wgAdyenCheckoutGatewayLogDebug) is true\n\n\t\t\t\tconfig.onBrand = function ( brandInfo ) {\n\t\t\t\t\tvar message = brandInfo.brand ?\n\t\t\t\t\t\t'onBrand returned brand: ' + brandInfo.brand :\n\t\t\t\t\t\t'onBrand returned: ' + JSON.stringify( brandInfo );\n\t\t\t\t\tif ( brandInfo.brand ) {\n\t\t\t\t\t\tonBrandSubmethod = brandInfo.brand;\n\t\t\t\t\t}\n\t\t\t\t\tmw.donationInterface.forms.addDebugMessage( message );\n\t\t\t\t};\n\n\t\t\t\tconfig.onBinLookup = function ( binLookupInfo ) {\n\t\t\t\t\tvar message = binLookupInfo.detectedBrands && binLookupInfo.detectedBrands.length > 0 ?\n\t\t\t\t\t\t'onBinLookup returned detected brands: ' + JSON.stringify( binLookupInfo.detectedBrands ) :\n\t\t\t\t\t\t'onBinLookup returned: ' + JSON.stringify( binLookupInfo );\n\t\t\t\t\tmw.donationInterface.forms.addDebugMessage( message );\n\t\t\t\t};\n\n\t\t\t\tconfig.showBrandsUnderCardNumber = false;\n\t\t\t\treturn config;\n\n\t\t\tcase 'ach':\n\t\t\tcase 'ideal':\n\t\t\tcase 'onlineBanking_CZ':\n\t\t\tcase 'sepadirectdebit':\n\t\t\t\t// for ach, ideal, CZ bank transfers, and sepa additional config is optional\n\t\t\t\treturn config;\n\n\t\t\tcase 'applepay':\n\t\t\t\t// for applepay, additional config is required\n\t\t\t\tvar amount = {},\n\t\t\t\t\tcurrency = $( '#currency' ).val(),\n\t\t\t\t\tamount_value = $( '#amount' ).val();\n\t\t\t\tamount.currency = currency;\n\t\t\t\tamount.value = amountInMinorUnits( amount_value, currency );\n\t\t\t\tconfig.amount = amount;\n\t\t\t\tconfig.countryCode = country;\n\t\t\t\tconfig.requiredBillingContactFields = [\n\t\t\t\t\t'name',\n\t\t\t\t\t'postalAddress'\n\t\t\t\t];\n\t\t\t\tconfig.requiredShippingContactFields = [\n\t\t\t\t\t'name',\n\t\t\t\t\t'email'\n\t\t\t\t];\n\n\t\t\t\tauthPromise = new Promise( function ( authResolve, authReject ) {\n\t\t\t\t\tconfig.onAuthorized = function ( resolve, reject, event ) {\n\t\t\t\t\t\tvar bContact = event.payment.billingContact,\n\t\t\t\t\t\t\tsContact = event.payment.shippingContact,\n\t\t\t\t\t\t\textraData = {};\n\t\t\t\t\t\textraData = getBestApplePayContactName( extraData, bContact, sContact );\n\t\t\t\t\t\textraData.postal_code = bContact.postalCode;\n\t\t\t\t\t\textraData.state_province = bContact.administrativeArea;\n\t\t\t\t\t\textraData.city = bContact.locality;\n\t\t\t\t\t\tif ( bContact.addressLines.length > 0 ) {\n\t\t\t\t\t\t\textraData.street_address = bContact.addressLines[ 0 ];\n\t\t\t\t\t\t}\n\t\t\t\t\t\textraData.email = sContact.emailAddress;\n\t\t\t\t\t\textraData.payment_submethod = mapAppleNetworkToSubmethod( event.payment.token.paymentMethod.network );\n\t\t\t\t\t\t// We will combine this contact data with a token from the\n\t\t\t\t\t\t// onSubmit event after both events have fired.\n\t\t\t\t\t\tauthResolve( extraData );\n\n\t\t\t\t\t\tresolve();\n\t\t\t\t\t};\n\t\t\t\t} );\n\t\t\t\t// For Apple Pay show the branded button with 'Donate with 🍎Pay'\n\t\t\t\t// text as opposed to our standard blue Donate button\n\t\t\t\tconfig.showPayButton = true;\n\t\t\t\tconfig.buttonType = 'donate';\n\t\t\t\t// When the donor clicks the donate button, this event is fired with\n\t\t\t\t// a validationUrl provided by Apple. We have to make a server-side\n\t\t\t\t// request to get a big blob of Apple Pay session data, then send it\n\t\t\t\t// via the resolve function back to the component, which apparently\n\t\t\t\t// sends it back to the native widget via completeMerchantValidation.\n\t\t\t\t// https://developer.apple.com/documentation/apple_pay_on_the_web/apple_pay_js_api/providing_merchant_validation\n\t\t\t\tconfig.onValidateMerchant = function ( resolve, reject, validationUrl ) {\n\t\t\t\t\tvar api = new mw.Api();\n\t\t\t\t\tapi.post( {\n\t\t\t\t\t\taction: 'di_applesession_adyen',\n\t\t\t\t\t\tvalidation_url: validationUrl,\n\t\t\t\t\t\twmf_token: $( '#wmf_token' ).val()\n\t\t\t\t\t} ).then( function ( data ) {\n\t\t\t\t\t\tif ( data.result && data.result.errors ) {\n\t\t\t\t\t\t\tmw.donationInterface.validation.showErrors( data.result.errors );\n\t\t\t\t\t\t\treject();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tresolve( data.session );\n\t\t\t\t\t\t}\n\t\t\t\t\t} );\n\t\t\t\t};\n\n\t\t\t\treturn config;\n\n\t\t\tcase GOOGLEPAY_COMPONENT_TYPE:\n\t\t\t\t// for googlepay, additional config is required\n\t\t\t\tvar g_amount = {},\n\t\t\t\t\tg_currency = $( '#currency' ).val(),\n\t\t\t\t\tg_amount_value = $( '#amount' ).val(),\n\t\t\t\t\tlanguagesSupportedByGPayButton = [\n\t\t\t\t\t\t'ar', 'bg', 'ca', 'cs', 'da', 'de', 'en', 'el', 'es', 'et', 'fi', 'fr', 'hr', 'id', 'it', 'ja',\n\t\t\t\t\t\t'ko', 'ms', 'nl', 'no', 'pl', 'pt', 'ru', 'sk', 'sl', 'sr', 'sv', 'th', 'tr', 'uk', 'zh'\n\t\t\t\t\t], baseLanguageCode = checkoutConfig.locale.slice( 0, 2 );\n\t\t\t\tg_amount.currency = g_currency;\n\t\t\t\tg_amount.value = amountInMinorUnits( g_amount_value, g_currency );\n\t\t\t\tconfig.amount = g_amount;\n\t\t\t\tconfig.countryCode = country;\n\t\t\t\tconfig.environment = configFromServer.environment.toUpperCase();\n\t\t\t\tconfig.showPayButton = true;\n\t\t\t\t// When we are showing the form in a language for which Google Pay has no\n\t\t\t\t// translations of their button text, use the plain 'GPay' button rather\n\t\t\t\t// than the 'Donate with GPay' button.\n\t\t\t\tif ( languagesSupportedByGPayButton.indexOf( baseLanguageCode ) === -1 ) {\n\t\t\t\t\tconfig.buttonType = 'plain';\n\t\t\t\t} else {\n\t\t\t\t\tconfig.buttonType = 'donate';\n\t\t\t\t}\n\t\t\t\tconfig.emailRequired = true;\n\t\t\t\tconfig.billingAddressRequired = true;\n\t\t\t\tconfig.allowedCardNetworks = configFromServer.googleAllowedNetworks;\n\t\t\t\tconfig.billingAddressParameters = {\n\t\t\t\t\tformat: 'FULL'\n\t\t\t\t};\n\t\t\t\t// called gatewayMerchantId but actually our account name with Adyen\n\t\t\t\tconfig.gatewayMerchantId = configFromServer.merchantAccountName;\n\t\t\t\tconfig.merchantId = configFromServer.googleMerchantId;\n\n\t\t\t\tauthPromise = new Promise( function ( authResolve ) {\n\t\t\t\t\tconfig.onAuthorized = function ( response ) {\n\t\t\t\t\t\tvar bContact = response.paymentMethodData.info.billingAddress,\n\t\t\t\t\t\t\textraData = {};\n\t\t\t\t\t\textraData.postal_code = bContact.postalCode;\n\t\t\t\t\t\textraData.state_province = bContact.administrativeArea;\n\t\t\t\t\t\textraData.city = bContact.locality;\n\t\t\t\t\t\textraData.street_address = bContact.address1;\n\t\t\t\t\t\textraData.email = response.email;\n\t\t\t\t\t\textraData.full_name = bContact.name;\n\t\t\t\t\t\textraData.payment_submethod = mapAdyenSubmethod(\n\t\t\t\t\t\t\tresponse.paymentMethodData.info.cardNetwork.toLowerCase()\n\t\t\t\t\t\t);\n\t\t\t\t\t\t// We will combine this contact data with a token from the\n\t\t\t\t\t\t// onSubmit event after both events have fired.\n\t\t\t\t\t\tauthResolve( extraData );\n\t\t\t\t\t};\n\t\t\t\t} );\n\t\t\t\treturn config;\n\n\t\t\tdefault:\n\t\t\t\tthrow new Error( 'Component type not found' );\n\t\t}\n\t}\n\n\t/**\n\t * Given an amount in major currency units, e.g. dollars, returns the\n\t * amount in minor units for the currency, e.g. cents. For non-fractional\n\t * currencies just rounds the amount to the nearest whole number.\n\t *\n\t * @param {number} amount\n\t * @param {string} currency\n\t * @return {number} amount in minor units for specified currency\n\t */\n\tfunction amountInMinorUnits( amount, currency ) {\n\t\tvar threeDecimals = mw.config.get( 'DonationInterfaceThreeDecimalCurrencies' ),\n\t\t\tnoDecimals = mw.config.get( 'DonationInterfaceNoDecimalCurrencies' );\n\n\t\tif ( noDecimals.indexOf( currency ) !== -1 ) {\n\t\t\treturn Math.round( amount );\n\t\t}\n\t\tif ( threeDecimals.indexOf( currency ) !== -1 ) {\n\t\t\treturn Math.round( amount * 1000 );\n\t\t}\n\t\treturn Math.round( amount * 100 );\n\t}\n\n\t/**\n\t * Set up Adyen Checkout object\n\t *\n\t * @param {Object} config requires clientKey, environment, locale,\n\t *  and paymentMethodsResponse\n\t * @return {AdyenCheckout}\n\t */\n\tfunction getCheckout( config ) {\n\t\tconfig.onSubmit = onSubmit;\n\t\tconfig.onAdditionalDetails = onAdditionalDetails;\n\t\tconfig.onError = onError;\n\t\tconfig.showPayButton = false;\n\t\tvar checkoutObject = new AdyenCheckout( config );\n\t\tif ( checkoutObject instanceof Promise ) {\n\t\t\treturn checkoutObject;\n\t\t}\n\n\t\treturn new Promise( function ( resolve, reject ) {\n\t\t\tresolve( checkoutObject );\n\t\t} );\n\t}\n\n\t/**\n\t * Try to obtain the \"best\" name from the available contact info sent back by Apple pay\n\t *\n\t * @see https://developer.apple.com/documentation/apple_pay_on_the_web/applepaypaymentrequest/2216120-requiredbillingcontactfields\n\t * @see https://developer.apple.com/documentation/apple_pay_on_the_web/applepaypaymentcontact\n\t * @param extraData\n\t * @param billingContact\n\t * @param shippingContact\n\t * @return {*}\n\t */\n\tfunction getBestApplePayContactName( extraData, billingContact, shippingContact ) {\n\t\tvar first_name, last_name;\n\n\t\tif ( billingContact && billingContact.givenName && billingContact.givenName.length > 1 ) {\n\t\t\tfirst_name = billingContact.givenName;\n\t\t\tif ( billingContact.familyName && billingContact.familyName.length > 1 ) {\n\t\t\t\tlast_name = billingContact.familyName;\n\t\t\t}\n\t\t}\n\n\t\tif ( first_name && !last_name ) {\n\t\t\t// suspected 'dad' scenario so use shipping contact\n\t\t\tif ( shippingContact && shippingContact.givenName && shippingContact.givenName.length > 1 ) {\n\t\t\t\tfirst_name = shippingContact.givenName;\n\t\t\t\tif ( shippingContact.familyName && shippingContact.familyName.length > 1 ) {\n\t\t\t\t\tlast_name = shippingContact.familyName;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\textraData.first_name = first_name;\n\t\textraData.last_name = last_name;\n\t\treturn extraData;\n\t}\n\n\tfunction mapAppleNetworkToSubmethod( network ) {\n\t\tnetwork = network.toLowerCase();\n\t\tswitch ( network ) {\n\t\t\tcase 'amex':\n\t\t\tcase 'discover':\n\t\t\tcase 'jcb':\n\t\t\tcase 'visa':\n\t\t\t\treturn network;\n\t\t\tcase 'cartesbancaires':\n\t\t\t\treturn 'cb';\n\t\t\tcase 'electron':\n\t\t\t\treturn 'visa-electron';\n\t\t\tcase 'mastercard':\n\t\t\t\treturn 'mc';\n\t\t\tdefault:\n\t\t\t\treturn '';\n\t\t}\n\t}\n\n\t/**\n\t * Get the name of the Adyen Checkout component to instantiate\n\t *\n\t * @param {string} paymentMethod our top-level payment method code\n\t * @return {string} name of Adyen Checkout component to instantiate\n\t */\n\tfunction mapPaymentMethodToComponentType( paymentMethod ) {\n\t\tswitch ( paymentMethod ) {\n\t\t\tcase 'dd':\n\t\t\t\treturn 'ach';\n\t\t\tcase 'cc':\n\t\t\t\treturn 'card';\n\t\t\tcase 'rtbt':\n\t\t\t\tif ( mw.config.get( 'payment_submethod' ) === 'sepadirectdebit' ) {\n\t\t\t\t\treturn 'sepadirectdebit';\n\t\t\t\t} else {\n\t\t\t\t\treturn 'ideal';\n\t\t\t\t}\n\t\t\tcase 'bt':\n\t\t\t\treturn 'onlineBanking_CZ';\n\t\t\tcase 'apple':\n\t\t\t\treturn 'applepay';\n\t\t\tcase 'google':\n\t\t\t\treturn GOOGLEPAY_COMPONENT_TYPE;\n\t\t\tdefault:\n\t\t\t\tthrow new Error( 'paymentMethod not found' );\n\t\t}\n\t}\n\n\t/**\n\t * TODO: should we do this mapping server-side\n\t * using SmashPig's ReferenceData?\n\t *\n\t * @param {string} adyenBrandCode Adyen-side identifier for the payment submethod\n\t * @return {string} Our identifier for the payment submethod\n\t */\n\tfunction mapAdyenSubmethod( adyenBrandCode ) {\n\t\tswitch ( adyenBrandCode ) {\n\t\t\tcase 'bijcard':\n\t\t\t\treturn 'bij';\n\t\t\tcase 'cartebancaire':\n\t\t\t\treturn 'cb';\n\t\t\tcase 'mc-debit':\n\t\t\t\treturn 'mc';\n\t\t\tcase 'visadankort':\n\t\t\t\treturn 'visa';\n\t\t\tcase 'visadebit':\n\t\t\tcase 'vpay':\n\t\t\t\treturn 'visa-debit';\n\t\t\tcase 'visabeneficial':\n\t\t\t\treturn 'visa-beneficial';\n\t\t\tcase 'visaelectron':\n\t\t\t\treturn 'visa-electron';\n\t\t\tcase 'mastercard':\n\t\t\t\treturn 'mc';\n\t\t\tdefault:\n\t\t\t\treturn adyenBrandCode;\n\t\t}\n\t}\n\n\tsubmitPromise = new Promise( function ( submitResolve, submitReject ) {\n\t\tonSubmit = function ( state, component ) {\n\t\t\tvar extraData = {};\n\t\t\t// Submit to our server, unless it's Apple Pay, which submits in\n\t\t\t// the onAuthorized handler.\n\t\t\tif ( mw.donationInterface.validation.validate() && state.isValid ) {\n\t\t\t\tswitch ( payment_method ) {\n\t\t\t\t\tcase 'dd':\n\t\t\t\t\t\textraData = {\n\t\t\t\t\t\t\tencrypted_bank_account_number: state.data.paymentMethod.encryptedBankAccountNumber,\n\t\t\t\t\t\t\tencrypted_bank_location_id: state.data.paymentMethod.encryptedBankLocationId,\n\t\t\t\t\t\t\tfull_name: state.data.paymentMethod.ownerName,\n\t\t\t\t\t\t\tbank_account_type: $( '#bank_account_type' ).val(),\n\t\t\t\t\t\t\t// below are billing address, optional but good to have for civi\n\t\t\t\t\t\t\tsupplemental_address_1: state.data.billingAddress.houseNumberOrName,\n\t\t\t\t\t\t\tcountry: state.data.billingAddress.country,\n\t\t\t\t\t\t\tstreet_address: state.data.billingAddress.street,\n\t\t\t\t\t\t\tpostal_code: state.data.billingAddress.postalCode,\n\t\t\t\t\t\t\tcity: state.data.billingAddress.city,\n\t\t\t\t\t\t\tstate_province: state.data.billingAddress.stateOrProvince\n\t\t\t\t\t\t};\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'rtbt':\n\t\t\t\t\t\tswitch ( state.data.paymentMethod.type ) {\n\t\t\t\t\t\t\tcase 'ideal':\n\t\t\t\t\t\t\t\textraData = {\n\t\t\t\t\t\t\t\t\t// issuer is bank chosen from dropdown\n\t\t\t\t\t\t\t\t\tissuer_id: state.data.paymentMethod.issuer,\n\t\t\t\t\t\t\t\t\tpayment_submethod: 'rtbt_ideal'\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'sepadirectdebit':\n\t\t\t\t\t\t\t\textraData = {\n\t\t\t\t\t\t\t\t\tfull_name: state.data.paymentMethod.ownerName,\n\t\t\t\t\t\t\t\t\t// The International Bank Account Number\n\t\t\t\t\t\t\t\t\tiban: state.data.paymentMethod.iban,\n\t\t\t\t\t\t\t\t\tpayment_submethod: 'sepadirectdebit'\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'bt':\n\t\t\t\t\t\textraData = {\n\t\t\t\t\t\t\t// issuer is bank chosen from dropdown\n\t\t\t\t\t\t\tissuer_id: state.data.paymentMethod.issuer\n\t\t\t\t\t\t};\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'cc':\n\t\t\t\t\t\textraData = {\n\t\t\t\t\t\t\tencrypted_card_number: state.data.paymentMethod.encryptedCardNumber,\n\t\t\t\t\t\t\tencrypted_expiry_month: state.data.paymentMethod.encryptedExpiryMonth,\n\t\t\t\t\t\t\tencrypted_expiry_year: state.data.paymentMethod.encryptedExpiryYear,\n\t\t\t\t\t\t\tencrypted_security_code: state.data.paymentMethod.encryptedSecurityCode,\n\t\t\t\t\t\t\t// The code should be available in state.data.paymentMethod.brand, but\n\t\t\t\t\t\t\t// sometimes it's not there. We can usually still find it via component.\n\t\t\t\t\t\t\tpayment_submethod: mapAdyenSubmethod(\n\t\t\t\t\t\t\t\tstate.data.paymentMethod.brand || component.state.brand || onBrandSubmethod\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t};\n\t\t\t\t\t\tif ( state.data.browserInfo ) {\n\t\t\t\t\t\t\textraData.color_depth = state.data.browserInfo.colorDepth;\n\t\t\t\t\t\t\textraData.java_enabled = state.data.browserInfo.javaEnabled;\n\t\t\t\t\t\t\textraData.screen_height = state.data.browserInfo.screenHeight;\n\t\t\t\t\t\t\textraData.screen_width = state.data.browserInfo.screenWidth;\n\t\t\t\t\t\t\textraData.time_zone_offset = state.data.browserInfo.timeZoneOffset;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'google':\n\t\t\t\t\t\tsubmitResolve( state.data.paymentMethod.googlePayToken );\n\t\t\t\t\t\treturn;\n\t\t\t\t\tcase 'apple':\n\t\t\t\t\t\t// Resolve the submit promise with the Apple Pay token and bail out - we\n\t\t\t\t\t\t// also need to wait for the onAuthorized event with contact data.\n\t\t\t\t\t\tsubmitResolve( state.data.paymentMethod.applePayToken );\n\t\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// Allow other scripts (e.g. variants) to provide more data to submit\n\t\t\t\tif ( typeof mw.donationInterface.getExtraData === 'function' ) {\n\t\t\t\t\tObject.assign( extraData, mw.donationInterface.getExtraData() );\n\t\t\t\t}\n\n\t\t\t\tmw.donationInterface.forms.callDonateApi(\n\t\t\t\t\thandleApiResult, extraData, 'di_donate_adyen'\n\t\t\t\t);\n\t\t\t}\n\t\t};\n\t} );\n\n\tfunction handleApiResult( result ) {\n\t\tif ( result.isFailed ) {\n\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\tgeneral: mw.msg( 'donate_interface-error-msg-general' )\n\t\t\t} );\n\t\t\treturn;\n\t\t}\n\n\t\tif ( result.formData && Object.keys( result.formData ).length > 0 ) {\n\t\t\t// FIXME: reconstructing the raw result from the API\n\t\t\t// which has been normalized down to just these two\n\t\t\t// fields. Should we just pass the raw Adyen API result\n\t\t\t// back to the front end? Seems like we would only want\n\t\t\t// a rawResult property on the front-end donation API\n\t\t\t// response when we are damn sure it's sanitized.\n\t\t\tcheckout.createFromAction( {\n\t\t\t\tpaymentMethodType: 'scheme',\n\t\t\t\turl: result.redirect,\n\t\t\t\tdata: result.formData,\n\t\t\t\tmethod: 'POST',\n\t\t\t\ttype: 'redirect'\n\t\t\t} ).mount( '#action-container' );\n\n\t\t// canShowModal() is just a sanity check to see if the required DOM elements\n\t\t// are there.\n\t\t} else if ( mw.monthlyConvert && mw.monthlyConvert.canShowModal() ) {\n\t\t\tmw.monthlyConvert.init();\n\t\t} else if ( result.redirect ) {\n\t\t\tdocument.location.replace( result.redirect );\n\t\t} else {\n\t\t\tdocument.location.replace( mw.config.get( 'DonationInterfaceThankYouPage' ) );\n\t\t}\n\t}\n\n\tfunction onAdditionalDetails( state, dropin ) {\n\t\t// Handle 3D secure\n\t}\n\n\t// T292571 try catch the adyen error, see if any connection been blocked, e.g. iframe\n\tfunction onError( error ) {\n\t\t// Ignore blank string - that means a previous error was cleared up\n\t\tif ( typeof error.error === 'string' && error.error === '' ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( typeof error.error === 'string' && error.error.slice( 0, 8 ) === 'error.va' ) {\n\t\t\t// T349600 Log validation error codes only if sf-cc-num.02 donate_interface-error-msg-card-number-do-not-match-card-brand)\n\t\t\t// with date time and time zone for adyen to investigate their card validation js issue\n\t\t\tif ( error.error === 'error.va.sf-cc-num.02' ) {\n\t\t\t\terror.error = 'Adyen error: ' + error.error + ' on ' + new Date().toString();\n\t\t\t} else {\n\t\t\t\treturn;\n\t\t\t}\n\t\t} else {\n\t\t\t// handle component error\n\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\tgeneral: mw.msg( 'donate_interface-error-msg-general' )\n\t\t\t} );\n\t\t}\n\t\tthrow error;\n\t}\n\n\tfunction setLocaleAndTranslations( config, localeFromServer ) {\n\t\t// Adyen supports the locales listed below, according to\n\t\t// https://docs.adyen.com/online-payments/web-components/localization-components#supported-languages\n\t\tvar adyenSupportedLocale = [\n\t\t\t'zh-CN', 'zh-TW', 'hr-HR', 'cs-CZ',\n\t\t\t'da-DK', 'nl-NL', 'en-US', 'fi-FI',\n\t\t\t'fr-FR', 'de-DE', 'el-GR', 'hu-HU',\n\t\t\t'it-IT', 'ja-JP', 'ko-KR', 'no-NO',\n\t\t\t'pl-PL', 'pt-BR', 'ro-RO', 'ru-RU',\n\t\t\t'sk-SK', 'sl-SL', 'es-ES', 'sv-SE'\n\t\t], baseLocaleFromServer = localeFromServer.slice( 0, 2 );\n\n\t\t// We support Norwegian Bokmal (nb) but Adyen's components just support the generic 'no' Norwegian code\n\t\tif ( baseLocaleFromServer === 'nb' ) {\n\t\t\tconfig.locale = 'no-NO';\n\t\t} else {\n\t\t\tconfig.locale = localeFromServer;\n\t\t}\n\n\t\tconfig.translations = {};\n\t\t// Check if donor's language is unsupported by Adyen and we need to provide our own customized translation\n\t\t// Adyen supports ar as Arabic - International and doesn't check the country part\n\t\tif ( baseLocaleFromServer !== 'ar' && adyenSupportedLocale.indexOf( config.locale ) === -1 ) {\n\t\t\tconfig.translations[ config.locale ] = {\n\t\t\t\t//title\n\t\t\t\t'creditCard.numberField.title': mw.msg( 'donate_interface-credit-card-number' ),\n\t\t\t\t'creditCard.expiryDateField.title': mw.msg( 'donate_interface-credit-card-expiration' ),\n\t\t\t\t'creditCard.cvcField.title': mw.msg( 'donate_interface-cvv' ),\n\t\t\t\t//placeholder\n\t\t\t\t'creditCard.expiryDateField.placeholder': mw.msg( 'donate_interface-expiry-date-field-placeholder' ),\n\t\t\t\t'creditCard.cvcField.placeholder.3digits': mw.msg( 'donate_interface-cvv-placeholder-3-digits' ),\n\t\t\t\t'creditCard.cvcField.placeholder.4digits': mw.msg( 'donate_interface-cvv-placeholder-4-digits' ),\n\t\t\t\t//error\n\t\t\t\t'creditCard.numberField.invalid': mw.msg( 'donate_interface-error-msg-invalid-card-number' ),\n\t\t\t\t'creditCard.expiryDateField.invalid': mw.msg( 'donate_interface-error-msg-expiry-date-field-invalid' ),\n\t\t\t\t'error.va.gen.01': mw.msg( 'donate_interface-error-msg-incomplete-field' ),\n\t\t\t\t'error.va.gen.02': mw.msg( 'donate_interface-error-msg-field-not-valid' ),\n\t\t\t\t'error.va.sf-cc-num.01': mw.msg( 'donate_interface-error-msg-invalid-card-number' ),\n\t\t\t\t'error.va.sf-cc-num.02': mw.msg( 'donate_interface-error-msg-card-number-do-not-match-card-brand' ),\n\t\t\t\t'error.va.sf-cc-num.03': mw.msg( 'donate_interface-error-msg-unsupported-card-entered' ),\n\t\t\t\t'error.va.sf-cc-dat.01': mw.msg( 'donate_interface-error-msg-card-too-old' ),\n\t\t\t\t'error.va.sf-cc-dat.02': mw.msg( 'donate_interface-error-msg-date-too-far-in-the-future' )\n\t\t\t};\n\t\t} else if ( config.locale === 'nl-NL' ) {\n\t\t\tconfig.translations[ config.locale ] = {\n\t\t\t\t'idealIssuer.selectField.placeholder': mw.msg( 'donate_interface-rtbt-issuer_id' )\n\t\t\t};\n\t\t} else if ( language === 'ja' ) {\n\t\t\tconfig.translations[ config.locale ] = {\n\t\t\t\t'creditCard.expiryDateField.placeholder': mw.msg( 'donate_interface-expiry-date-field-placeholder' )\n\t\t\t};\n\t\t} else {\n\t\t\tconfig.translations[ config.locale ] = {};\n\t\t}\n\n\t\t// Allow other scripts (e.g. variants) to provide more translations to the Adyen components\n\t\tif ( mw.donationInterface.extraTranslations ) {\n\t\t\tObject.assign( config.translations[ config.locale ], mw.donationInterface.extraTranslations );\n\t\t}\n\t}\n\n\t/**\n\t * Runs as soon as the external Adyen checkout script is loaded\n\t */\n\tfunction setup() {\n\t\tvar component_type,\n\t\t\tconfig,\n\t\t\tcontainerName = 'component-container',\n\t\t\toldShowErrors,\n\t\t\tcheckoutPromise;\n\n\t\tif ( !configFromServer ) {\n\t\t\t// If the configuration has not been passed from the server, we are likely on the\n\t\t\t// ResultSwitcher page and have just been loaded incidentally to make a form for\n\t\t\t// a backdrop of the monthly convert popup. As the rest of this function is only\n\t\t\t// needed to set up payment widgets which will not be needed here, just quit.\n\t\t\t// It might be better to stop loading adyen.js in that situation, but that's a\n\t\t\t// bigger refactor than we want to do right now.\n\t\t\treturn;\n\t\t}\n\n\t\tcomponent_type = mapPaymentMethodToComponentType( payment_method );\n\n\t\t// Drop in the adyen components placeholder container\n\t\t$( '.submethods' ).before(\n\t\t\t'<div id=\"' + containerName + '\" />'\n\t\t).before(\n\t\t\t'<div id=\"action-container\" />'\n\t\t);\n\n\t\t// add name placeholder for ja JP\n\t\tif ( language === 'ja' ) {\n\t\t\t$( '#last_name' ).attr( 'placeholder', '鈴木' );\n\t\t\t$( '#first_name' ).attr( 'placeholder', '太郎' );\n\t\t}\n\n\t\t// Override validation's showErrors function to add error\n\t\t// highlights to the outer div around the secure field iframe.\n\t\t// FIXME: cleaner object-oriented JS with inheritance would\n\t\t// make this prettier. See https://phabricator.wikimedia.org/T293287\n\t\toldShowErrors = mw.donationInterface.validation.showErrors;\n\t\tmw.donationInterface.validation.showErrors = function ( errors ) {\n\t\t\tvar adyenFieldName;\n\t\t\t$.each( errors, function ( field ) {\n\t\t\t\tadyenFieldName = false;\n\t\t\t\tif ( field === 'card_num' || field === 'encrypted_card_number' ) {\n\t\t\t\t\tadyenFieldName = 'encryptedCardNumber';\n\t\t\t\t} else if ( field === 'encrypted_expiry_month' || field === 'encrypted_expiry_year' ) {\n\t\t\t\t\tadyenFieldName = 'encryptedExpiryDate';\n\t\t\t\t} else if ( field === 'cvv' ) {\n\t\t\t\t\tadyenFieldName = 'encryptedSecurityCode';\n\t\t\t\t}\n\t\t\t\tif ( adyenFieldName ) {\n\t\t\t\t\t$( 'span[data-cse=' + adyenFieldName + ']' )\n\t\t\t\t\t\t.closest( '.adyen-checkout__input-wrapper' )\n\t\t\t\t\t\t.addClass( 'errorHighlight' );\n\t\t\t\t}\n\t\t\t} );\n\t\t\toldShowErrors( errors );\n\t\t};\n\n\t\t// Copy values to leave the mw.config setting untouched\n\t\tconfig = {\n\t\t\tclientKey: configFromServer.clientKey,\n\t\t\tenvironment: configFromServer.environment,\n\t\t\tpaymentMethodsResponse: configFromServer.paymentMethodsResponse\n\t\t};\n\n\t\tsetLocaleAndTranslations( config, configFromServer.locale );\n\n\t\tcheckoutPromise = getCheckout( config );\n\t\tcheckoutPromise.then( function ( checkoutObject ) {\n\t\t\tcheckout = checkoutObject;\n\t\t\tcreateAndMountComponent( config, component_type, containerName );\n\t\t} );\n\t}\n\n\tfunction createAndMountComponent( config, component_type, containerName ) {\n\t\tvar component_config = getComponentConfig( component_type, config ),\n\t\t\tcomponent = checkout.create( component_type, component_config );\n\n\t\tif ( component_type === GOOGLEPAY_COMPONENT_TYPE ) {\n\t\t\tcomponent.isAvailable().then( function () {\n\t\t\t\tcomponent.mount( '#' + containerName );\n\t\t\t} ).catch( function () {\n\t\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\t\tgeneral: mw.message(\n\t\t\t\t\t\t'donate_interface-error-msg-google_pay_unsupported',\n\t\t\t\t\t\tmw.config.get( 'DonationInterfaceOtherWaysURL' )\n\t\t\t\t\t).plain()\n\t\t\t\t} );\n\t\t\t} );\n\t\t\t// For Google Pay, we need contact data from the onAuthorized event and token\n\t\t\t// data from the onSubmit event before we can make our MediaWiki API call.\n\t\t\tPromise.all( [ submitPromise, authPromise ] ).then( function ( values ) {\n\t\t\t\tvar extraData = values[ 1 ];\n\t\t\t\textraData.payment_token = values[ 0 ];\n\t\t\t\tmw.donationInterface.forms.callDonateApi(\n\t\t\t\t\thandleApiResult, extraData, 'di_donate_adyen'\n\t\t\t\t);\n\t\t\t} ).catch( function ( err ) {\n\t\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\t\tgeneral: mw.msg( 'donate_interface-error-msg-general' )\n\t\t\t\t} );\n\t\t\t\t// Let error bubble up to window.onerror handler so the errorLog\n\t\t\t\t// module sends it to our client-side logging endpoint.\n\t\t\t\tthrow err;\n\t\t\t} );\n\t\t} else if ( component_type === 'applepay' ) {\n\t\t\tcomponent.isAvailable().then( function () {\n\t\t\t\tcomponent.mount( '#' + containerName );\n\t\t\t} ).catch( function () {\n\t\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\t\tgeneral: mw.message(\n\t\t\t\t\t\t'donate_interface-error-msg-apple_pay_unsupported',\n\t\t\t\t\t\tmw.config.get( 'DonationInterfaceOtherWaysURL' )\n\t\t\t\t\t).plain()\n\t\t\t\t} );\n\t\t\t} );\n\t\t\t// For Apple Pay, we need contact data from the onAuthorized event and token\n\t\t\t// data from the onSubmit event before we can make our MediaWiki API call.\n\t\t\tPromise.all( [ submitPromise, authPromise ] ).then( function ( values ) {\n\t\t\t\tvar extraData = values[ 1 ];\n\t\t\t\textraData.payment_token = values[ 0 ];\n\t\t\t\tmw.donationInterface.forms.callDonateApi(\n\t\t\t\t\thandleApiResult, extraData, 'di_donate_adyen'\n\t\t\t\t);\n\t\t\t} ).catch( function ( err ) {\n\t\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\t\tgeneral: mw.msg( 'donate_interface-error-msg-general' )\n\t\t\t\t} );\n\t\t\t\t// Let error bubble up to window.onerror handler so the errorLog\n\t\t\t\t// module sends it to our client-side logging endpoint.\n\t\t\t\tthrow err;\n\t\t\t} );\n\t\t} else {\n\t\t\ttry {\n\t\t\t\tcomponent.mount( '#' + containerName );\n\t\t\t} catch ( err ) {\n\t\t\t\tmw.donationInterface.validation.showErrors( {\n\t\t\t\t\tgeneral: mw.msg( 'donate_interface-error-msg-general' )\n\t\t\t\t} );\n\t\t\t\tthrow err;\n\t\t\t}\n\t\t\t// For everything except Apple and google\n\t\t\t// Pay, show our standard 'Donate' button\n\t\t\t$( '#paymentSubmit' ).show();\n\t\t\t$( '#paymentSubmitBtn' ).click( mw.util.debounce( function ( evt ) {\n\t\t\t\tcomponent.submit( evt );\n\t\t\t}, 100 ) );\n\t\t}\n\t}\n\n\t/**\n\t * On documentready we create a script tag and wire it up to run setup as soon as it\n\t * is loaded, or to show an error message if the external script can't be loaded.\n\t * The script should already be mostly or completely preloaded at this point, thanks\n\t * to a <link rel=preload> we add in AdyenCheckoutGateway::addGatewaySpecificResources\n\t */\n\n\tfunction loadScript( type ) {\n\t\tvar scriptNode = document.createElement( 'script' );\n\t\tscriptNode.onerror = function () {\n\t\t\tmw.donationInterface.validation.showErrors(\n\t\t\t\t{ general: 'Could not load payment provider Javascript. Please reload or try again later.' }\n\t\t\t);\n\t\t};\n\t\tif ( type === 'adyen' ) {\n\t\t\tscriptNode.onload = setup;\n\t\t\tscriptNode.crossOrigin = 'anonymous';\n\t\t\tscriptNode.integrity = configFromServer.script.integrity;\n\t\t\tscriptNode.src = configFromServer.script.src;\n\t\t} else {\n\t\t\tscriptNode.src = configFromServer.googleScript;\n\t\t}\n\n\t\tdocument.body.append( scriptNode );\n\t}\n\n\t$( function () {\n\t\tif ( payment_method === 'google' ) {\n\t\t\tloadScript( 'google' );\n\t\t}\n\t\tloadScript( 'adyen' );\n\t} );\n} )( jQuery, mediaWiki );\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/amazon_gateway/amazon.js","messages":[{"ruleId":"prefer-regex-literals","severity":1,"message":"Use a regular expression literal instead of the 'RegExp' constructor.","line":14,"column":23,"nodeType":"NewExpression","messageId":"unexpectedRegExp","endLine":14,"endColumn":44,"suggestions":[{"messageId":"replaceWithLiteral","fix":{"range":[598,619],"text":"/^Atza/"},"desc":"Replace with an equivalent regular expression literal."}]},{"ruleId":"no-jquery/no-sizzle","severity":1,"message":"Selector extensions are not allowed","line":268,"column":8,"nodeType":"CallExpression","endLine":268,"endColumn":45}],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/*global amazon:true, OffAmazonPayments:true*/\n( function ( $, mw ) {\n\tvar clientId = mw.config.get( 'wgAmazonGatewayClientID' ),\n\t\tsellerId = mw.config.get( 'wgAmazonGatewaySellerID' ),\n\t\tsandbox = mw.config.get( 'wgAmazonGatewaySandbox' ),\n\t\treturnUrl = mw.config.get( 'wgAmazonGatewayReturnURL' ),\n\t\twidgetScript = mw.config.get( 'wgAmazonGatewayWidgetScript' ),\n\t\tloginScript = mw.config.get( 'wgAmazonGatewayLoginScript' ),\n\t\tfailPage = mw.config.get( 'wgAmazonGatewayFailPage' ),\n\t\tisRecurring = $( '#recurring' ).val(),\n\t\tloggedIn = false,\n\t\tloginError,\n\t\taccessToken,\n\t\tvalidTokenPattern = new RegExp( '^Atza' ),\n\t\tbillingAgreementId,\n\t\torderReferenceId,\n\t\trecurConsentGranted = false,\n\t\tcardSelected = false,\n\t\tcardSelectTimeout,\n\t\t// If no card selected after this long, show link to other ways to give\n\t\t// in case the donor has no cards registered with Amazon\n\t\tCARD_SELECT_DELAY = 5000;\n\n\t$( function () {\n\t\t// Add a couple divs to hold the widgets\n\t\t$( '.submethods' ).before(\n\t\t\t'<div id=\"consentWidget\" />' +\n\t\t\t'<div id=\"walletWidget\" />' +\n\t\t\t'<div id=\"amazonLogin\" />'\n\t\t);\n\t\t// Set the click handler\n\t\t$( '#paymentSubmitBtn' ).click( submitPayment );\n\t} );\n\n\t// Adapted from Amazon documentation, will get parameters from fragment as\n\t// well as querystring and accepts Amazon's custom delimiters\n\tfunction getURLParameter( name, source ) {\n\t\tvar pattern = '[?&#]' + name + '=([^&;#]*)',\n\t\t\tmatches = new RegExp( pattern ).exec( source ) || [ '', '' ],\n\t\t\tvalue = matches[ 1 ].replace( /\\+/g, '%20' );\n\n\t\treturn decodeURIComponent( value ) || null;\n\t}\n\n\tfunction loadScript( url ) {\n\t\tvar a = document.createElement( 'script' );\n\t\ta.type = 'text/javascript';\n\t\ta.async = true;\n\t\ta.src = url;\n\t\tdocument.head.appendChild( a );\n\t}\n\n\tfunction redirectToLogin() {\n\t\t$( '#overlay' ).show();\n\t\tvar loginOptions = {\n\t\t\tscope: 'payments:widget',\n\t\t\tpopup: false\n\t\t};\n\t\tamazon.Login.authorize( loginOptions, returnUrl );\n\t}\n\n\tfunction addErrorMessage( message ) {\n\t\t$( '#topError' ).append(\n\t\t\t$( '<p class=\"error\">' + message + '</p>' )\n\t\t);\n\t\t$( '#errorReference' )\n\t\t\t.removeClass( 'errorMsgHide' )\n\t\t\t.addClass( 'errorMsg' );\n\t}\n\n\tfunction reloadPage() {\n\t\tvar qsParams = $( '#payment-form' ).serializeArray();\n\t\tdocument.location.replace( mw.util.getUrl( 'Special:AmazonGateway', qsParams ) );\n\t}\n\n\tfunction showErrorAndLoginButton( message ) {\n\t\tif ( message ) {\n\t\t\taddErrorMessage( message );\n\t\t}\n\t\tOffAmazonPayments.Button(\n\t\t\t'amazonLogin',\n\t\t\tsellerId,\n\t\t\t{\n\t\t\t\ttype: 'PwA',\n\t\t\t\tcolor: 'Gold',\n\t\t\t\tsize: 'large',\n\t\t\t\tauthorization: reloadPage\n\t\t\t}\n\t\t);\n\t}\n\n\tfunction tokenExpired() {\n\t\t// Re-create widget so it displays timeout error message\n\t\tcreateWalletWidget();\n\t\tshowErrorAndLoginButton();\n\t}\n\n\taccessToken = getURLParameter( 'access_token', location.hash );\n\tloginError = getURLParameter( 'error', location.search );\n\n\t// This will be called as soon as the login script is loaded\n\twindow.onAmazonLoginReady = function () {\n\n\t\tamazon.Login.setClientId( clientId );\n\t\tamazon.Login.setUseCookie( true );\n\t\tamazon.Login.setSandboxMode( sandbox );\n\t\tif ( !loggedIn ) {\n\t\t\tif ( loginError ) {\n\t\t\t\tshowErrorAndLoginButton(\n\t\t\t\t\tgetURLParameter( 'error_description', location.search )\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\tredirectToLogin();\n\t\t\t}\n\t\t}\n\t};\n\n\twindow.onAmazonPaymentsReady = function () {\n\t\tvar tokenLifetime;\n\t\tif ( loggedIn ) {\n\t\t\ttokenLifetime = parseInt( getURLParameter( 'expires_in', location.hash ), 10 );\n\t\t\tcreateWalletWidget();\n\t\t\tsetTimeout( tokenExpired, tokenLifetime * 1000 );\n\t\t}\n\t};\n\n\tif ( typeof accessToken === 'string' && accessToken.match( validTokenPattern ) ) {\n\t\t// Payment widgets need this cookie\n\t\tdocument.cookie = 'amazon_Login_accessToken=' + accessToken + ';secure';\n\t\tloggedIn = true;\n\t\tloadScript( widgetScript ); // This will load the login script for you\n\t} else {\n\t\tif ( loginError ) {\n\t\t\t// Load the full widget script to display a button\n\t\t\tloadScript( widgetScript );\n\t\t} else {\n\t\t\t// The first time around, only load the login script.\n\t\t\tloadScript( loginScript );\n\t\t}\n\t}\n\n\tfunction showOtherWaysLink() {\n\t\tvar url = mw.config.get( 'wgAmazonGatewayOtherWaysURL' ),\n\t\t\ttext = mw.message( 'donate_interface-otherways-short' );\n\t\taddErrorMessage( '<a href=\"' + url + '\">' + text + '</a>' );\n\t}\n\n\tfunction setSubmitVisibility() {\n\t\tvar show = true;\n\t\tif ( !cardSelected ) {\n\t\t\tshow = false;\n\t\t}\n\t\tif ( isRecurring && !recurConsentGranted ) {\n\t\t\tshow = false;\n\t\t}\n\t\tif ( show ) {\n\t\t\t$( '#paymentSubmit' ).show();\n\t\t} else {\n\t\t\t$( '#paymentSubmit' ).hide();\n\t\t}\n\t}\n\n\tfunction createWalletWidget() {\n\t\tvar params = {\n\t\t\tsellerId: sellerId,\n\t\t\tonReady: function ( billingAgreement ) {\n\t\t\t\tif ( !cardSelected ) {\n\t\t\t\t\tcardSelectTimeout = setTimeout( showOtherWaysLink, CARD_SELECT_DELAY );\n\t\t\t\t}\n\t\t\t\tif ( !billingAgreementId ) {\n\t\t\t\t\tbillingAgreementId = billingAgreement.getAmazonBillingAgreementId();\n\t\t\t\t\tif ( isRecurring ) {\n\t\t\t\t\t\tcreateConsentWidget();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t},\n\t\t\tagreementType: isRecurring ? 'BillingAgreement' : 'OrderReference',\n\t\t\tonOrderReferenceCreate: function ( orderReference ) {\n\t\t\t\tif ( orderReferenceId ) {\n\t\t\t\t\t// Redisplaying for an existing order, no need to continue\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\torderReferenceId = orderReference.getAmazonOrderReferenceId();\n\t\t\t},\n\t\t\tonPaymentSelect: function () {\n\t\t\t\tif ( !cardSelected ) {\n\t\t\t\t\tcardSelected = true;\n\t\t\t\t\tsetSubmitVisibility();\n\t\t\t\t}\n\t\t\t\tif ( cardSelectTimeout ) {\n\t\t\t\t\tclearTimeout( cardSelectTimeout );\n\t\t\t\t\tcardSelectTimeout = false;\n\t\t\t\t}\n\t\t\t},\n\t\t\tdesign: {\n\t\t\t\tdesignMode: 'responsive'\n\t\t\t},\n\t\t\tonError: function ( error ) {\n\t\t\t\t// Error message appears directly in widget\n\t\t\t\tshowErrorAndLoginButton();\n\t\t\t}\n\t\t};\n\t\t// If we are refreshing the widget to display a correctable error,\n\t\t// we need to set the Amazon order reference ID for continuity\n\t\tif ( orderReferenceId ) {\n\t\t\tparams.amazonOrderReferenceId = orderReferenceId;\n\t\t}\n\t\tif ( billingAgreementId ) {\n\t\t\tparams.amazonBillingAgreementId = billingAgreementId;\n\t\t}\n\t\tnew OffAmazonPayments.Widgets.Wallet( params ).bind( 'walletWidget' );\n\t}\n\n\tfunction handleConsentStatus( billingAgreementConsentStatus ) {\n\t\t// getConsentStatus returns a string for some reason\n\t\trecurConsentGranted =\n\t\t\t( billingAgreementConsentStatus.getConsentStatus() === 'true' );\n\t\tsetSubmitVisibility();\n\t}\n\n\tfunction createConsentWidget() {\n\t\tvar params = {\n\t\t\tsellerId: sellerId,\n\t\t\tamazonBillingAgreementId: billingAgreementId,\n\t\t\tdesign: {\n\t\t\t\tdesignMode: 'responsive'\n\t\t\t},\n\t\t\tonReady: handleConsentStatus,\n\t\t\tonConsent: handleConsentStatus,\n\t\t\tonError: function ( error ) {\n\t\t\t\tshowErrorAndLoginButton();\n\t\t\t}\n\t\t};\n\t\t$( '#consentWidget' ).show();\n\t\tnew OffAmazonPayments.Widgets.Consent( params ).bind( 'consentWidget' );\n\t}\n\n\tfunction handleErrors( errors ) {\n\t\tvar code,\n\t\t\trefreshWallet = false;\n\n\t\tfor ( code in errors ) {\n\t\t\tif ( !Object.prototype.hasOwnProperty.call( errors, code ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif ( code === 'token-mismatch' ) {\n\t\t\t\t// Session has expired, we need to reload the whole page.\n\t\t\t\t// FIXME: something nicer than an alert box\n\t\t\t\talert( errors[ code ] );\n\t\t\t\treloadPage();\n\t\t\t}\n\t\t\taddErrorMessage( errors[ code ] );\n\t\t\tif ( code === 'InvalidPaymentMethod' ) {\n\t\t\t\t// Card declined, but they can try another\n\t\t\t\trefreshWallet = true;\n\t\t\t}\n\t\t}\n\n\t\tif ( refreshWallet ) {\n\t\t\t// Redisplay the widget to show an error and let the donor pick a different card\n\t\t\tcardSelected = false;\n\t\t\tsetSubmitVisibility();\n\t\t\tcreateWalletWidget();\n\t\t}\n\t}\n\n\tfunction lockDonationAmount() {\n\t\tif ( $( '#amount_input' ).is( ':visible' ) ) {\n\t\t\t$( '#amount_input' ).hide();\n\t\t\t$( '#selected-amount' )\n\t\t\t\t.text( $( '#amount' ).val() + ' ' + $( '#currency' ).val() )\n\t\t\t\t.show();\n\t\t}\n\t}\n\n\tfunction submitPayment() {\n\t\tif ( !mw.donationInterface.validation.validateAmount() ) {\n\t\t\treturn;\n\t\t}\n\t\tif ( !cardSelected ) {\n\t\t\tshowOtherWaysLink();\n\t\t\treturn;\n\t\t}\n\t\tif ( isRecurring && !recurConsentGranted ) {\n\t\t\t//TODO: error message\n\t\t\treturn;\n\t\t}\n\t\t$( '#topError' ).html( '' );\n\t\t$( '#errorReference' )\n\t\t\t.removeClass( 'errorMsg' )\n\t\t\t.addClass( 'errorMsgHide' );\n\t\t$( '#overlay' ).show();\n\t\tlockDonationAmount();\n\t\tvar postdata = {\n\t\t\taction: 'di_amazon_bill',\n\t\t\tformat: 'json',\n\t\t\trecurring: isRecurring,\n\t\t\tamount: $( '#amount' ).val(),\n\t\t\tcurrency: $( '#currency' ).val(),\n\t\t\twmf_token: $( '#wmf_token' ).val()\n\t\t};\n\n\t\tif ( isRecurring ) {\n\t\t\tpostdata.billingAgreementId = billingAgreementId;\n\t\t} else {\n\t\t\tpostdata.orderReferenceId = orderReferenceId;\n\t\t}\n\n\t\t$.ajax( {\n\t\t\turl: mw.util.wikiScript( 'api' ),\n\t\t\tdata: postdata,\n\t\t\tdataType: 'json',\n\t\t\ttype: 'POST',\n\t\t\tsuccess: function ( data ) {\n\t\t\t\tif ( data.errors ) {\n\t\t\t\t\t$( '#overlay' ).hide();\n\t\t\t\t\thandleErrors( data.errors );\n\t\t\t\t} else if ( data.redirect ) {\n\t\t\t\t\tlocation.href = data.redirect;\n\t\t\t\t} else {\n\t\t\t\t\tlocation.href = failPage;\n\t\t\t\t}\n\t\t\t},\n\t\t\terror: function () {\n\t\t\t\tlocation.href = failPage;\n\t\t\t}\n\t\t} );\n\t}\n} )( jQuery, mediaWiki );\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/braintree_gateway/forms/braintree.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/composer.json","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"no-extra-parens","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/dlocal_gateway/forms/dlocal.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/extension.json","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"no-extra-parens","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/ingenico_gateway/forms/js/ingenico.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/iframe.liberator.js","messages":[{"ruleId":"no-redeclare","severity":1,"message":"'self' is already defined as a built-in global variable.","line":1,"column":10,"nodeType":"Block","messageId":"redeclaredAsBuiltin","endLine":1,"endColumn":14}],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/*global self:false */\n$( function () {\n\t// we're going to immediately redirect.\n\t// Hide the page contents (skin, mostly) so it doesn't appear in the iframe while we're waiting for the reload.\n\tjQuery( 'body' ).children().attr( 'style', 'display:none' );\n} );\ntop.location = self.document.location + '&liberated=1';\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.alwaysRedirect.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.emailPreferences.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.employerAutoComplete.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.employerExplain.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.employerExplainAlt.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.errorLog.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.forms.js","messages":[{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"$\" type.","line":4,"column":1,"nodeType":"Block","endLine":4,"endColumn":1},{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"mw\" type.","line":5,"column":1,"nodeType":"Block","endLine":5,"endColumn":1},{"ruleId":"no-jquery/no-sizzle","severity":1,"message":"Selector extensions are not allowed","line":74,"column":25,"nodeType":"CallExpression","endLine":74,"endColumn":67},{"ruleId":"jsdoc/no-undefined-types","severity":1,"message":"The type 'result' is undefined.","line":105,"column":1,"nodeType":"Block","endLine":105,"endColumn":1},{"ruleId":"es-x/no-object-assign","severity":2,"message":"ES2015 'Object.assign' method is forbidden.","line":162,"column":4,"nodeType":"MemberExpression","messageId":"forbidden","endLine":162,"endColumn":17},{"ruleId":"no-jquery/no-sizzle","severity":1,"message":"Selector extensions are not allowed","line":249,"column":8,"nodeType":"CallExpression","endLine":249,"endColumn":62}],"suppressedMessages":[],"errorCount":1,"fatalErrorCount":0,"warningCount":5,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/**\n * Core functionality for DonationInterface forms\n *\n * @param $\n * @param mw\n */\n( function ( $, mw ) {\n\tvar di = mw.donationInterface; // Defined in ext.donationInterface.validation.js\n\n\t// Common helper functions\n\tfunction disablePaymentSubmitButton() {\n\t\t$( '#paymentSubmitBtn' ).prop( 'disabled', true );\n\t\t$( '#paymentSubmitBtn' ).removeClass( 'enabled' ).addClass( 'disabled' );\n\t}\n\n\tfunction enablePaymentSubmitButton() {\n\t\t$( '#paymentSubmitBtn' ).prop( 'disabled', false );\n\t\t$( '#paymentSubmitBtn' ).removeClass( 'disabled' ).addClass( 'enabled' );\n\t}\n\n\t/**\n\t * Disable all interaction with the form, including buttons.\n\t * Usually done by drawing a semi-opaque overlay.\n\t */\n\tfunction disableForm() {\n\t\t$( '#overlay' ).show();\n\t\tdisablePaymentSubmitButton();\n\t}\n\n\t/**\n\t * Mark all form input fields disabled. This can be used to indicate that\n\t * no revision to donor info is possible after a card iframe is opened.\n\t */\n\tfunction disableInput() {\n\t\t$( '[type=text], [type=number], [type=email], select' ).each( function () {\n\t\t\t$( this ).attr( 'disabled', true );\n\t\t} );\n\t}\n\n\t/**\n\t * Makes a form disabled with disableForm usable again.\n\t */\n\tfunction enableForm() {\n\t\t$( '#overlay' ).hide();\n\t\tenablePaymentSubmitButton();\n\t}\n\n\t/**\n\t * Re-enable input fields disabled with disableInput.\n\t */\n\tfunction enableInput() {\n\t\t$( '[type=text], [type=number], [type=email] select' ).each( function () {\n\t\t\t$( this ).removeAttr( 'disabled' );\n\t\t} );\n\t}\n\n\t/**\n\t * Submit a basic form.\n\t */\n\tfunction submitForm() {\n\t\tdi.forms.disable();\n\t\tdi.forms.clean();\n\t\t$( '#payment-form' )[ 0 ].submit();\n\t}\n\n\tfunction cleanInput() {\n\t\t// Trim all the trimmable inputs\n\t\t$( '[type=text], [type=number], [type=email]' ).each( function () {\n\t\t\t$( this ).val( $.trim( this.value ) );\n\t\t} );\n\t}\n\n\tfunction resetSubmethod() {\n\t\tvar $submethodInput = $( 'input:radio[name=payment_submethod]' );\n\t\tif ( $submethodInput.length > 1 ) {\n\t\t\t$submethodInput.prop( 'checked', false );\n\t\t}\n\t}\n\n\t/**\n\t * Get a trinary value from a checkbox that may exist, falling back\n\t *  to a querystring value.\n\t *  '0' = checkbox shown and not checked, or 0 on querystring\n\t *  '1' = checkbox shown and checked, or 1 on querystring\n\t *  '' = checkbox not shown, querystring value missing\n\t *\n\t * @return {string}\n\t */\n\tfunction getOptIn() {\n\t\tvar val, $element = $( 'input[name=opt_in]:checked' );\n\t\tif ( $element.length === 1 ) {\n\t\t\tval = $element.val();\n\t\t} else {\n\t\t\tval = mw.util.getParamValue( 'opt_in' );\n\t\t\tif ( val === null ) {\n\t\t\t\tval = '';\n\t\t\t}\n\t\t}\n\t\treturn val;\n\t}\n\n\t/**\n\t * Call the generic donation API and handle errors or execute a callback\n\t *\n\t * @param {function(result)} successCallback will be called with response's 'result' property\n\t * @param {Array} extraData will be merged into the data collected from the form\n\t * @param {string} action action param to pass to MW API, defaults to 'donate'\n\t */\n\tfunction callDonateApi( successCallback, extraData, action ) {\n\t\tdi.forms.disable();\n\t\tdi.forms.clean();\n\t\t$( '#topError' ).html( '' );\n\t\t$( '#errorReference' )\n\t\t\t.removeClass( 'errorMsg' )\n\t\t\t.addClass( 'errorMsgHide' );\n\t\t$( '#paymentContinueBtn' ).removeClass( 'enabled' );\n\n\t\tvar sendData,\n\t\t\tpaymentSubmethod;\n\n\t\tif ( typeof $( 'input[name=\"payment_submethod\"]:checked' ).val() === 'undefined' ) {\n\t\t\tpaymentSubmethod = '';\n\t\t} else {\n\t\t\tpaymentSubmethod = $( 'input[name=\"payment_submethod\"]:checked' ).val().toLowerCase();\n\t\t}\n\n\t\tsendData = {\n\t\t\taction: action || 'donate',\n\t\t\tgateway: $( '#gateway' ).val(),\n\t\t\tcontact_id: $( '#contact_id' ).val(),\n\t\t\tcontact_hash: $( '#contact_hash' ).val(),\n\t\t\tcurrency: $( '#currency' ).val(),\n\t\t\tamount: $( '#amount' ).val(),\n\t\t\tfirst_name: $( '#first_name' ).val(),\n\t\t\tlast_name: $( '#last_name' ).val(),\n\t\t\tstreet_address: $( '#street_address' ).val(),\n\t\t\tcity: $( '#city' ).val(),\n\t\t\tstate_province: $( '#state_province' ).val(),\n\t\t\tpostal_code: $( '#postal_code' ).val(),\n\t\t\tphone: $( '#phone' ).val(),\n\t\t\temail: $( '#email' ).val(),\n\t\t\tcountry: $( '#country' ).val(),\n\t\t\tpayment_method: $( '#payment_method' ).val(),\n\t\t\tlanguage: $( '#language' ).val(),\n\t\t\tpayment_submethod: paymentSubmethod,\n\t\t\tprocessor_form: $( '#processor_form' ).val(),\n\t\t\tissuer_id: $( '#issuer_id' ).val(),\n\t\t\tutm_source: $( '#utm_source' ).val(),\n\t\t\tutm_campaign: $( '#utm_campaign' ).val(),\n\t\t\tutm_medium: $( '#utm_medium' ).val(),\n\t\t\treferrer: $( '#referrer' ).val(),\n\t\t\trecurring: $( '#recurring' ).val(),\n\t\t\tvariant: $( '#variant' ).val(),\n\t\t\twmf_token: $( '#wmf_token' ).val(),\n\t\t\topt_in: getOptIn(),\n\t\t\temployer: $( '#employer' ).val(),\n\t\t\temployer_id: $( '#employer_id' ).val(),\n\t\t\tformat: 'json'\n\t\t};\n\n\t\tif ( extraData ) {\n\t\t\tObject.assign( sendData, extraData );\n\t\t}\n\n\t\t// If debug logging is enabled and there are debug messages, send them.\n\t\tif ( mw.config.get( 'wgDonationInterfaceLogDebug' ) &&\n\t\t\tdi.forms.debugMessages.length > 0 ) {\n\t\t\tsendData.debug_messages = di.forms.debugMessages.join( '\\n' );\n\t\t}\n\n\t\t$.ajax( {\n\t\t\turl: mw.util.wikiScript( 'api' ),\n\t\t\tdata: sendData,\n\t\t\tdataType: 'json',\n\t\t\ttype: 'POST',\n\t\t\tsuccess: function ( data ) {\n\t\t\t\tif ( typeof data.error !== 'undefined' ) {\n\t\t\t\t\t// FIXME alert sux\n\t\t\t\t\talert( mw.msg( 'donate_interface-error-msg-general' ) );\n\t\t\t\t\t// Show continue button in 2nd section if it exists\n\t\t\t\t\t$( '#paymentContinue' ).show();\n\t\t\t\t} else if ( typeof data.result !== 'undefined' ) {\n\t\t\t\t\tif ( data.result.errors ) {\n\t\t\t\t\t\tmw.donationInterface.validation.showErrors( data.result.errors );\n\t\t\t\t\t\t// Show continue button in 2nd section if it exists\n\t\t\t\t\t\t$( '#paymentContinue' ).show();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tsuccessCallback( data.result );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t},\n\t\t\terror: function ( xhr ) {\n\t\t\t\t// FIXME too\n\t\t\t\talert( mw.msg( 'donate_interface-error-msg-general' ) );\n\t\t\t},\n\t\t\tcomplete: function () {\n\t\t\t\tdi.forms.enable();\n\t\t\t}\n\t\t} );\n\t}\n\n\tfunction isIframe() {\n\t\tvar payment_method = $( '#payment_method' ).val();\n\n\t\tswitch ( payment_method ) {\n\t\tcase 'cc':\n\t\t\treturn true;\n\t\tdefault:\n\t\t\treturn false;\n\t\t}\n\t}\n\n\t// FIXME: move function declarations into object\n\tdi.forms = {\n\t\tdisable: disableForm,\n\t\tdisableInput: disableInput,\n\t\tenable: enableForm,\n\t\tenableInput: enableInput,\n\t\tclean: cleanInput,\n\t\t// Gateways with more complex form submission can overwrite this\n\t\t// property with their own submission function.\n\t\tsubmit: submitForm,\n\t\tcallDonateApi: callDonateApi,\n\t\tisIframe: isIframe,\n\t\tresetSubmethod: resetSubmethod,\n\t\tgetOptIn: getOptIn,\n\t\tdebugMessages: [],\n\t\taddDebugMessage: function ( message ) {\n\t\t\tdi.forms.debugMessages.push( message );\n\t\t}\n\t};\n\n\t$( function () {\n\n\t\tvar $emailDiv = $( '#email' ).closest( 'div' ),\n\t\t\temailExplainMessage = mw.msg( 'donate_interface-email-explain' ),\n\t\t\toptInValue = mw.donationInterface.forms.getOptIn(),\n\t\t\thasSetClientVariablesError = mw.config.get( 'DonationInterfaceSetClientVariablesError' );\n\n\t\tif ( hasSetClientVariablesError ) {\n\t\t\tlocation.assign( mw.config.get( 'DonationInterfaceFailUrl' ) );\n\t\t\treturn;\n\t\t}\n\n\t\t$( '#first_name' ).focus();\n\n\t\t// If submethods are visible, and a submethod is already selected on\n\t\t// page load, clear it.\n\t\tif ( $( 'input[name=\"payment_submethod\"]:checked:visible' ).length > 0 ) {\n\t\t\tdi.forms.resetSubmethod();\n\t\t}\n\n\t\t// Submit on submethod click if valid, otherwise clear submethod selection.\n\t\t$( 'input[name=\"payment_submethod\"]' ).on( 'click', function () {\n\t\t\tif ( di.validation.validate() ) {\n\t\t\t\tdi.forms.submit();\n\t\t\t} else {\n\t\t\t\tdi.forms.resetSubmethod();\n\t\t\t\treturn false;\n\t\t\t}\n\t\t} );\n\n\t\t// Some forms show a 'continue' button when validation errors are found\n\t\t// server-side on the initial submit. When shown, it should validate\n\t\t// and submit the form.\n\t\t$( '#paymentContinueBtn' ).on( 'click', function () {\n\t\t\tif ( di.validation.validate() ) {\n\t\t\t\tdi.forms.submit();\n\t\t\t}\n\t\t} );\n\n\t\t// Only load employer autocomplete js when the employer field is visible\n\t\tif ( $( '#employer' ).length ) {\n\t\t\tmw.loader.load( 'ext.donationInterface.employerAutoComplete' );\n\t\t}\n\n\t\t// Magic to hopefully disable the spinner in case we are returned to this\n\t\t// page via the Back button.\n\t\t$( window ).on(\n\t\t\t'unload', function () {\n\t\t\t\t// wrapped in case it is overwritten\n\t\t\t\tdi.forms.enable();\n\t\t\t\tdi.forms.enableInput();\n\t\t\t}\n\t\t);\n\n\t\tfunction showEmailExplain() {\n\t\t\t$emailDiv.after( '<div id=\"email_explain\">' + emailExplainMessage + '</div>' );\n\t\t}\n\n\t\tif ( optInValue === '0' ) {\n\t\t\tshowEmailExplain();\n\t\t}\n\t} );\n} )( jQuery, mediaWiki );\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.jaVariant02.js","messages":[{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"mw\" type.","line":8,"column":1,"nodeType":"Block","endLine":8,"endColumn":1},{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"$\" type.","line":9,"column":1,"nodeType":"Block","endLine":9,"endColumn":1}],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/**\n * Experiment to determine whether different placeholder text and extra name\n * fields improve donation rates in Japan. Once tests are concluded and optimal\n * text is decided, please make the optimal text standard and delete this and\n * the extension.json module configuration for ext.donationInterface.jaVariant02\n * and ext.donationInterface.adyenCheckoutWithJaVariant02.\n *\n * @param mw\n * @param $\n */\n\n( function ( mw, $ ) {\n\tmw.donationInterface = mw.donationInterface || {};\n\tmw.donationInterface.getExtraData = function () {\n\t\treturn {\n\t\t\tfirst_name_phonetic: $( '#first_name_phonetic' ).val(),\n\t\t\tlast_name_phonetic: $( '#last_name_phonetic' ).val()\n\t\t};\n\t};\n} )( mediaWiki, jQuery );\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.monthlyConvert.js","messages":[{"ruleId":"no-shadow","severity":1,"message":"'currency' is already declared in the upper scope on line 3 column 3.","line":26,"column":49,"nodeType":"Identifier","messageId":"noShadow","endLine":26,"endColumn":57},{"ruleId":"no-shadow","severity":1,"message":"'currency' is already declared in the upper scope on line 3 column 3.","line":34,"column":39,"nodeType":"Identifier","messageId":"noShadow","endLine":34,"endColumn":47}],"suppressedMessages":[{"ruleId":"no-jquery/no-fade","severity":2,"message":"Prefer CSS transitions to .fadeOut","line":171,"column":6,"nodeType":"CallExpression","endLine":175,"endColumn":9,"suppressions":[{"kind":"directive","justification":""}]},{"ruleId":"no-jquery/no-fade","severity":2,"message":"Prefer CSS transitions to .fadeIn","line":172,"column":7,"nodeType":"CallExpression","endLine":172,"endColumn":38,"suppressions":[{"kind":"directive","justification":""}]},{"ruleId":"no-jquery/no-fade","severity":2,"message":"Prefer CSS transitions to .fadeIn","line":173,"column":7,"nodeType":"CallExpression","endLine":173,"endColumn":31,"suppressions":[{"kind":"directive","justification":""}]},{"ruleId":"no-jquery/no-fade","severity":2,"message":"Prefer CSS transitions to .fadeOut","line":180,"column":6,"nodeType":"CallExpression","endLine":180,"endColumn":31,"suppressions":[{"kind":"directive","justification":""}]},{"ruleId":"no-jquery/no-fade","severity":2,"message":"Prefer CSS transitions to .fadeOut","line":181,"column":6,"nodeType":"CallExpression","endLine":183,"endColumn":9,"suppressions":[{"kind":"directive","justification":""}]},{"ruleId":"no-jquery/no-fade","severity":2,"message":"Prefer CSS transitions to .fadeIn","line":182,"column":7,"nodeType":"CallExpression","endLine":182,"endColumn":33,"suppressions":[{"kind":"directive","justification":""}]}],"errorCount":0,"fatalErrorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":"( function ( $, mw ) {\n\tvar mc = {},\n\t\tcurrency,\n\t\toriginalAmount,\n\t\t// These config vars are set in GatewayPage::setClientVariables\n\t\ttyUrl = mw.config.get( 'wgDonationInterfaceThankYouUrl' ),\n\t\t// This is set to the ask amounts for the selected currency, or null\n\t\t// if there are no amounts set for it.\n\t\tconvertAmounts = mw.config.get( 'wgDonationInterfaceMonthlyConvertAmounts' );\n\n\tmc.getConvertAsk = function ( amount ) {\n\t\tvar i,\n\t\t\tnumAmounts;\n\t\tif ( !convertAmounts ) {\n\t\t\treturn 0;\n\t\t}\n\t\tnumAmounts = convertAmounts.length;\n\t\tfor ( i = 0; i < numAmounts; i++ ) {\n\t\t\tif ( amount <= convertAmounts[ i ][ 0 ] ) {\n\t\t\t\treturn convertAmounts[ i ][ 1 ];\n\t\t\t}\n\t\t}\n\t\treturn 0;\n\t};\n\n\tmc.setConvertAsk = function ( suggestedAmount, currency, locale ) {\n\t\tvar convertAmountFormatted = mc.formatAmount(\n\t\t\tsuggestedAmount, currency, locale\n\t\t);\n\t\t$( '.mc-convert-ask' ).text( convertAmountFormatted );\n\t\t$( '.mc-modal-screen' ).show();\n\t};\n\n\tmc.formatAmount = function ( amount, currency, locale ) {\n\t\tvar formattedAmount;\n\n\t\ttry {\n\t\t\tformattedAmount = amount.toLocaleString(\n\t\t\t\tlocale,\n\t\t\t\t{\n\t\t\t\t\tcurrency: currency,\n\t\t\t\t\tstyle: 'currency'\n\t\t\t\t}\n\t\t\t);\n\t\t} catch ( e ) {\n\t\t\t// Assume a two decimal place currency for fallback\n\t\t\tformattedAmount = currency + ' ' + amount.toFixed( 2 );\n\t\t}\n\t\treturn formattedAmount;\n\t};\n\n\tmc.postMonthlyConvertDonate = function ( amount, declineMonthlyConvert ) {\n\t\tvar sendData = {\n\t\t\taction: 'di_recurring_convert',\n\t\t\tformat: 'json',\n\t\t\tgateway: $( '#gateway' ).val(),\n\t\t\twmf_token: $( '#wmf_token' ).val(),\n\t\t\tamount: amount\n\t\t},\n\t\t\turl;\n\t\tif ( declineMonthlyConvert ) {\n\t\t\tsendData.declineMonthlyConvert = declineMonthlyConvert;\n\t\t}\n\t\t$.ajax( {\n\t\t\turl: mw.util.wikiScript( 'api' ),\n\t\t\tdata: sendData,\n\t\t\tdataType: 'json',\n\t\t\ttype: 'POST',\n\t\t\tsuccess: function ( data ) {\n\t\t\t\tif ( data && !data.error && data.result && !data.result.errors ) {\n\t\t\t\t\turl = new mw.Uri( tyUrl );\n\t\t\t\t\tif ( !declineMonthlyConvert ) {\n\t\t\t\t\t\turl = url.extend( { recurringConversion: 1 } );\n\t\t\t\t\t}\n\t\t\t\t\tdocument.location.assign( url.toString() );\n\t\t\t\t} else {\n\t\t\t\t\t// FIXME - alert sux. Not much donor can do at this point.\n\t\t\t\t\t// We should let 'em know the recurring conversion failed\n\t\t\t\t\t// but the initial donation worked, then show them the thank\n\t\t\t\t\t// you page.\n\t\t\t\t\tif ( !declineMonthlyConvert ) {\n\t\t\t\t\t\talert( mw.msg( 'donate_interface-monthly-convert-error' ) );\n\t\t\t\t\t}\n\t\t\t\t\tdocument.location.assign( tyUrl );\n\t\t\t\t}\n\t\t\t},\n\t\t\terror: function () {\n\t\t\t\t// FIXME too\n\t\t\t\tif ( !declineMonthlyConvert ) {\n\t\t\t\t\talert( mw.msg( 'donate_interface-monthly-convert-error' ) );\n\t\t\t\t}\n\t\t\t\tdocument.location.assign( tyUrl );\n\t\t\t}\n\t\t} );\n\t};\n\n\t// TODO Unify logic for determining whether or not to show monthly convert. This\n\t// is just a sanity check to see if the required DOM elements are there.\n\tmc.canShowModal = function () {\n\t\treturn $( '.mc-modal-screen' ).length > 0;\n\t};\n\tmc.init = function () {\n\t\tvar presetAmount,\n\t\t\tlocale = $( '#language' ).val() + '-' + $( '#country' ).val();\n\t\toriginalAmount = +$( '#amount' ).val();\n\t\tcurrency = $( '#currency' ).val();\n\t\tpresetAmount = mc.presetAmount || mc.getConvertAsk( originalAmount );\n\t\tif ( presetAmount === 0 && tyUrl !== null ) {\n\t\t\t// They're donating in an unsupported currency, or are\n\t\t\t// outside of the range where it makes sense to ask for\n\t\t\t// a monthly donation. Just send them to the TY page.\n\t\t\tdocument.location.assign( tyUrl );\n\t\t} else {\n\t\t\tmc.setConvertAsk(\n\t\t\t\tpresetAmount,\n\t\t\t\tcurrency,\n\t\t\t\tlocale\n\t\t\t);\n\t\t\t$( '.mc-no-button, .mc-close' ).on( 'click keypress', function ( e ) {\n\t\t\t\tif ( e.which === 13 || e.type === 'click' ) {\n\t\t\t\t\tmc.postMonthlyConvertDonate( presetAmount, true );\n\t\t\t\t}\n\t\t\t} );\n\t\t\t$( '.mc-yes-button' ).on( 'click keypress', function ( e ) {\n\t\t\t\tif ( e.which === 13 || e.type === 'click' ) {\n\t\t\t\t\tmc.postMonthlyConvertDonate( presetAmount );\n\t\t\t\t}\n\t\t\t} );\n\t\t\t$( '.mc-donate-monthly-button' ).on( 'click keypress', function ( e ) {\n\t\t\t\tif ( e.which === 13 || e.type === 'click' ) {\n\t\t\t\t\tvar $otherAmountField = $( '#mc-other-amount-input' ),\n\t\t\t\t\t\totherAmount = +$otherAmountField.val(),\n\t\t\t\t\t\trates = mw.config.get( 'wgDonationInterfaceCurrencyRates' ),\n\t\t\t\t\t\trate,\n\t\t\t\t\t\tminUsd = mw.config.get( 'wgDonationInterfacePriceFloor' ),\n\t\t\t\t\t\tminLocal,\n\t\t\t\t\t\tformattedMin,\n\t\t\t\t\t\t$smallAmountMessage;\n\n\t\t\t\t\tif ( rates[ currency ] ) {\n\t\t\t\t\t\trate = rates[ currency ];\n\t\t\t\t\t} else {\n\t\t\t\t\t\trate = 1;\n\t\t\t\t\t}\n\t\t\t\t\tminLocal = minUsd * rate;\n\t\t\t\t\tif ( otherAmount < minLocal ) {\n\t\t\t\t\t\tformattedMin = mc.formatAmount(\n\t\t\t\t\t\t\tminLocal, currency, locale\n\t\t\t\t\t\t);\n\t\t\t\t\t\t$otherAmountField.addClass( 'errorHighlight' );\n\t\t\t\t\t\t$smallAmountMessage = $( '#mc-error-smallamount' );\n\t\t\t\t\t\t$smallAmountMessage.text(\n\t\t\t\t\t\t\t$smallAmountMessage.text().replace( '$1', formattedMin )\n\t\t\t\t\t\t);\n\t\t\t\t\t\t$( '#mc-error-largeamount' ).hide();\n\t\t\t\t\t\t$smallAmountMessage.show();\n\t\t\t\t\t} else if ( otherAmount > originalAmount ) {\n\t\t\t\t\t\t$otherAmountField.addClass( 'errorHighlight' );\n\t\t\t\t\t\t$( '#mc-error-smallamount' ).hide();\n\t\t\t\t\t\t$( '#mc-error-largeamount' ).show();\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$( '.mc-error' ).hide();\n\t\t\t\t\t\t$otherAmountField.removeClass( 'errorHighlight' );\n\t\t\t\t\t\tmc.postMonthlyConvertDonate( otherAmount );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} );\n\t\t\t/* eslint-disable no-jquery/no-fade */\n\t\t\t$( '.mc-diff-amount-link' ).on( 'click keypress', function ( e ) {\n\t\t\t\tif ( e.which === 13 || e.type === 'click' ) {\n\t\t\t\t\t$( '.mc-choice' ).fadeOut( function () {\n\t\t\t\t\t\t$( '.mc-edit-amount' ).fadeIn();\n\t\t\t\t\t\t$( '.mc-back' ).fadeIn();\n\t\t\t\t\t\t$( '.mc-other-amount-input' ).focus();\n\t\t\t\t\t} );\n\t\t\t\t}\n\t\t\t} );\n\t\t\t$( '.mc-back' ).on( 'click keypress', function ( e ) {\n\t\t\t\tif ( e.which === 13 || e.type === 'click' ) {\n\t\t\t\t\t$( '.mc-back' ).fadeOut();\n\t\t\t\t\t$( '.mc-edit-amount' ).fadeOut( function () {\n\t\t\t\t\t\t$( '.mc-choice' ).fadeIn();\n\t\t\t\t\t} );\n\t\t\t\t}\n\t\t\t} );\n\t\t\t/* eslint-enable no-jquery/no-fade */\n\t\t}\n\n\t};\n\t$( function () {\n\t\tif ( mw.config.get( 'showMConStartup' ) ) {\n\t\t\tmc.init();\n\t\t}\n\t} );\n\tmw.monthlyConvert = mc;\n} )( jQuery, mediaWiki );\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.monthlyConvertButtonFlip.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.monthlyConvertMultiplier.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.monthlyConvert_003.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.monthlyConvert_010.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.monthlyConvert_011.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.recurUpgrade.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/ext.donationInterface.validation.js","messages":[{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"$\" type.","line":7,"column":1,"nodeType":"Block","endLine":7,"endColumn":1},{"ruleId":"jsdoc/require-param-type","severity":1,"message":"Missing JSDoc @param \"mw\" type.","line":8,"column":1,"nodeType":"Block","endLine":8,"endColumn":1},{"ruleId":"no-shadow","severity":1,"message":"'i' is already declared in the upper scope on line 39 column 45.","line":40,"column":35,"nodeType":"Identifier","messageId":"noShadow","endLine":40,"endColumn":36}],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":3,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/* globals Mailcheck */\n/**\n * Client-side validation logic for DonationInterface\n * For starters, we just redirect to the existing global functions.\n * They should be rewritten here when we modernize the remaining forms.\n *\n * @param $\n * @param mw\n */\n( function ( $, mw ) {\n\tvar di = mw.donationInterface = mw.donationInterface || {},\n\t\tcheckMail = true,\n\t\tmcDomains = Mailcheck.defaultDomains.concat( [\n\t\t\t'aim.com', 'alice.it', 'aon.at', 'bellsouth.net', 'bigpond.com',\n\t\t\t'bigpond.net.au', 'blueyonder.co.uk', 'btinternet.com',\n\t\t\t'btopenworld.com', 'charter.net', 'cox.net', 'docomo.ne.jp',\n\t\t\t'earthlink.net', 'email.it', 'embarqmail.com', 'ezweb.ne.jp',\n\t\t\t'fastwebnet.it', 'free.fr', 'frontier.com', 'gmx.at', 'gmx.de',\n\t\t\t'gmx.net', 'hetnet.nl', 'home.nl', 'i.softbank.jp', 'iinet.net.au',\n\t\t\t'inwind.it', 'juno.com', 'laposte.net', 'libero.it',\n\t\t\t'mindspring.com', 'netscape.net', 'neuf.fr', 'nifty.com',\n\t\t\t'ntlworld.com', 'o2.pl', 'online.no', 'optonline.net',\n\t\t\t'optusnet.com.au', 'orange.fr', 'pacbell.net', 'planet.nl',\n\t\t\t'q.com', 'qq.com','roadrunner.com', 'rocketmail.com',\n\t\t\t'rogers.com', 'seznam.cz', 'sfr.fr', 'shaw.ca', 'sky.com',\n\t\t\t'skynet.be', 'sympatico.ca', 'talktalk.net', 'telefonica.net',\n\t\t\t'telenet.be', 'telia.com', 'telus.net', 'tin.it',\n\t\t\t'tiscali.co.uk', 'tiscali.it', 'tpg.com.au', 'umich.edu',\n\t\t\t'uol.com.br', 'videotron.ca', 'virgilio.it', 'wanadoo.fr',\n\t\t\t'web.de', 'windstream.net', 'wp.pl', 'xs4all.nl', 'xtra.co.nz',\n\t\t\t'ybb.ne.jp', 'ymail.com', 'ziggo.nl'\n\t\t] ),\n\t\tmultiCountrySubdomains = [ 'yahoo', 'hotmail', 'outlook', 'live' ],\n\t\tcountryTlds = [\n\t\t\t'ca', 'cl', 'co.id', 'co.il', 'co.in', 'co.jp', 'co.uk', 'com.ar',\n\t\t\t'com.au', 'com.br', 'com.mx', 'com.pe', 'com.sg', 'cz', 'de', 'es',\n\t\t\t'fr', 'it', 'jp', 'kr', 'nl', 'pt', 'se'\n\t\t];\n\t$.each( multiCountrySubdomains, function ( i, subdomain ) {\n\t\t$.each( countryTlds, function ( i, countryTld ) {\n\t\t\tmcDomains.push( subdomain + '.' + countryTld );\n\t\t} );\n\t} );\n\n\tfunction showErrors( errors ) {\n\t\tvar generalErrors = [];\n\n\t\t$.each( errors, function ( field, message ) {\n\t\t\tvar $messageField = $( '#' + field + 'Msg' );\n\n\t\t\tif ( $messageField.length > 0 ) {\n\t\t\t\t$( '#' + field ).addClass( 'errorHighlight' );\n\t\t\t\t$messageField\n\t\t\t\t\t.removeClass( 'errorMsgHide' )\n\t\t\t\t\t.addClass( 'errorMsg' )\n\t\t\t\t\t.text( message );\n\t\t\t} else {\n\t\t\t\tgeneralErrors.push( message );\n\t\t\t}\n\t\t} );\n\t\tif ( generalErrors.length > 0 ) {\n\t\t\t$( '#topError' ).html(\n\t\t\t\tgeneralErrors.join( '<br/>' )\n\t\t\t);\n\t\t\t$( '#errorReference' )\n\t\t\t\t.removeClass( 'errorMsgHide' )\n\t\t\t\t.addClass( 'errorMsg' );\n\t\t}\n\t}\n\n\t/**\n\t * Are any errors currently showing, from either server-side or\n\t * client-side validation?\n\t *\n\t * @return {boolean}\n\t */\n\tfunction hasErrors() {\n\t\treturn $( '.errorMsg' ).length > 0;\n\t}\n\n\tdi.validation = {\n\t\tvalidate: function () {\n\t\t\t// This funkiness is to make sure we run all the validations and\n\t\t\t// highlight bad values, rather than short-circuiting the second\n\t\t\t// group of tests if \"&&\" detects that the first tests failed.\n\t\t\tvar results = [\n\t\t\t\t\tthis.validateAmount(),\n\t\t\t\t\tthis.validatePersonal()\n\t\t\t\t],\n\t\t\t\t// Fail if one or more tests failed.\n\t\t\t\tsuccess = ( results.indexOf( false ) === -1 );\n\n\t\t\treturn success;\n\t\t},\n\t\t// FIXME: Move global scope functions here\n\t\tvalidateAmount: window.validateAmount,\n\t\tvalidatePersonal: window.validate_personal,\n\t\tshowErrors: showErrors,\n\t\thasErrors: hasErrors\n\t};\n\n\t// Set up email error detection and correction\n\t$( document ).on( 'blur', '#email', function () {\n\t\tif ( !checkMail ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Be really conservative - only catch two letter errors\n\t\tMailcheck.domainThreshold = 2; // No way to set from opts!\n\t\t$( this ).mailcheck( {\n\t\t\ttopLevelDomains: [],\n\t\t\tdomains: mcDomains,\n\t\t\tsuggested: function ( element, suggestion ) {\n\t\t\t\tvar message = mw.msg(\n\t\t\t\t\t'donate_interface-did-you-mean',\n\t\t\t\t\tsuggestion.full\n\t\t\t\t);\n\t\t\t\t$( '#emailSuggestion' ).show();\n\t\t\t\t$( '#emailSuggestion span' ).html( message );\n\t\t\t},\n\t\t\tempty: function ( element ) {\n\t\t\t\t$( '#emailSuggestion' ).hide();\n\t\t\t}\n\t\t} );\n\t} );\n\t$( document ).on( 'click', '#emailSuggestion .correction', function () {\n\t\t$( '#email' ).val( $( this ).text() );\n\t\t$( '#emailSuggestion' ).hide();\n\t} );\n\t$( document ).on( 'click', '#emailSuggestion .close-button', function () {\n\t\tcheckMail = false; // Don't bother them again\n\t\t$( '#emailSuggestion' ).hide();\n\t} );\n} )( jQuery, mediaWiki );\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/js/skinOverride.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/modules/validate_input.js","messages":[{"ruleId":"jsdoc/require-returns","severity":1,"message":"Missing JSDoc @return declaration.","line":1,"column":1,"nodeType":"Block","endLine":4,"endColumn":4},{"ruleId":"no-shadow","severity":1,"message":"'value' is already declared in the upper scope on line 83 column 6.","line":106,"column":27,"nodeType":"Identifier","messageId":"noShadow","endLine":106,"endColumn":32},{"ruleId":"mediawiki/msg-doc","severity":1,"message":"All possible message keys should be documented. See https://w.wiki/4r9a for details.","line":108,"column":14,"nodeType":"CallExpression","endLine":108,"endColumn":64},{"ruleId":"no-shadow","severity":1,"message":"'i' is already declared in the upper scope on line 86 column 3.","line":114,"column":32,"nodeType":"Identifier","messageId":"noShadow","endLine":114,"endColumn":33}],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":"/**\n * Validate the donation amount to make sure it is formatted correctly and at least a minimum amount.\n * TODO: also validate ceiling\n */\nwindow.validateAmount = function () {\n\tvar error = true,\n\t\tamount = $( 'input[name=\"amount\"]' ).val(), // get the amount\n\t\tcurrency = '',\n\t\trates = mw.config.get( 'wgDonationInterfaceCurrencyRates' ),\n\t\tamountRules = mw.config.get( 'wgDonationInterfaceAmountRules' ),\n\t\tminimumInDonationCurrency,\n\t\tminDisplay,\n\t\tmessage = mediaWiki.msg( 'donate_interface-smallamount-error' ),\n\t\t$amountMsg = $( '#amountMsg' ),\n\t\tthreeDecimalCurrencies = [ 'BHD', 'CLF', 'IQD', 'KWD', 'LYD',\n\t\t\t'MGA', 'MRO', 'OMR', 'TND' ];\n\n\t// Check amount is at least the minimum\n\tif ( $( 'input[name=\"currency\"]' ).length ) {\n\t\tcurrency = $( 'input[name=\"currency\"]' ).val();\n\t}\n\tif ( $( 'select[name=\"currency\"]' ).length ) {\n\t\tcurrency = $( 'select[name=\"currency\"]' ).val();\n\t}\n\n\t// Normalize weird amount formats.\n\t// Don't mess with these unless you know what you're doing.\n\t/*jshint ignore:start*/\n\tamount = amount.replace( /[,.](\\d)$/, '\\:$10' );\n\tamount = amount.replace( /[,.](\\d)(\\d)$/, '\\:$1$2' );\n\tif ( threeDecimalCurrencies.indexOf( currency ) > -1 ) {\n\t\tamount = amount.replace( /[,.](\\d)(\\d)(\\d)$/, '\\:$1$2$3' );\n\t}\n\tamount = amount.replace( /[,.]/g, '' );\n\tamount = amount.replace( /:/, '.' );\n\t$( 'input[name=\"amount\"]' ).val( amount ); // set the new amount back into the form\n\t/*jshint ignore:end*/\n\n\t// Check amount is a real number, sets error as true (good) if no issues\n\terror = ( amount === null || isNaN( amount ) || amount.value <= 0 );\n\n\tif ( currency === amountRules.currency || ( typeof rates[ currency ] ) === 'undefined' ) {\n\t\tminimumInDonationCurrency = amountRules.min;\n\t} else {\n\t\t// Rates are all relative to USD, so we divide the configured minimum by its corresponding\n\t\t// rate to get the minimum in USD, then multiply by the rate of the donation currency to get\n\t\t// the minimum in the donation currency.\n\t\tminimumInDonationCurrency = amountRules.min / rates[ amountRules.currency ] * rates[ currency ];\n\t}\n\t// if we're on a new form, clear existing amount error\n\t$amountMsg.removeClass( 'errorMsg' ).addClass( 'errorMsgHide' ).text( '' );\n\tif ( ( amount < minimumInDonationCurrency ) || error ) {\n\t\t// Round to two decimal places (TODO: no decimals for some currencies)\n\t\tminDisplay = Math.round( minimumInDonationCurrency * 100 ) / 100;\n\t\tmessage = message.replace( '$1', minDisplay + ' ' + currency );\n\t\t$amountMsg.removeClass( 'errorMsgHide' ).addClass( 'errorMsg' ).text( message );\n\n\t\terror = true;\n\t\t// See if we're on a webitects accordion form\n\t\tif ( $( '#step1wrapper' ).length ) {\n\t\t\t$( '#step1wrapper' ).slideDown();\n\t\t\t$( '#paymentContinue' ).show();\n\t\t\t// If we're on an Ingenico iframe form, slide up the 3rd step to force the user to\n\t\t\t// generate a new iframe after they change the form.\n\t\t\tif ( $( '#payment iframe' ).length ) {\n\t\t\t\t$( '#step3wrapper' ).slideUp();\n\t\t\t}\n\t\t}\n\t\t$( '#other-amount' ).val( '' );\n\t\t$( '#other-amount' ).focus();\n\t}\n\treturn !error;\n};\n\n/**\n * Validates the personal information fields\n * FIXME: Bad name, this validates more than just personal info.\n * Move the good parts to ext.donationInterface.validation.js\n *\n * @return {boolean} true if no errors, false otherwise (also uses in-page error messages to notify the user)\n */\nwindow.validate_personal = function () {\n\tvar value, countryField, emailAdd, invalid, apos, dotpos, domain,\n\t\terrorsPresent = false,\n\t\t$formField,\n\t\ti,\n\t\tinvalids = [ '..', '/', '\\\\', ',', '<', '>' ],\n\t\trules = mediaWiki.config.get( 'wgDonationInterfaceValidationRules' ) || [];\n\n\tfunction clearError( field ) {\n\t\t$( '#' + field ).removeClass( 'errorHighlight' );\n\t\t$( '#' + field + 'Msg' )\n\t\t\t.removeClass( 'errorMsg' )\n\t\t\t.addClass( 'errorMsgHide' );\n\t}\n\n\tfunction setError( field, message ) {\n\t\terrorsPresent = true;\n\t\t$( '#' + field ).addClass( 'errorHighlight' );\n\t\t$( '#' + field + 'Msg' )\n\t\t\t.removeClass( 'errorMsgHide' )\n\t\t\t.addClass( 'errorMsg' )\n\t\t\t.text( message );\n\t}\n\n\tfunction isEmpty( field, value ) {\n\t\treturn !$.trim( value ) ||\n\t\t\tvalue === mediaWiki.msg( 'donate_interface-donor-' + field );\n\t}\n\n\t// Generically defined rules set by GatewayAdapter->getClientSideValidationRules\n\t$.each( rules, function ( fieldKey, ruleList ) {\n\t\tclearError( fieldKey );\n\t\t$.each( ruleList, function ( i, rule ) {\n\t\t\tvar failed = false;\n\t\t\t$formField = $( '#' + fieldKey );\n\t\t\tif ( $formField.length === 0 ) {\n\t\t\t\t// Radio button special case. First see if the group exists ...\n\t\t\t\t$formField = $( 'input[name=' + fieldKey + ']' );\n\t\t\t\tif ( $formField.length > 0 ) {\n\t\t\t\t\t// ... then filter to just the selected button\n\t\t\t\t\t$formField = $formField.filter( ':checked' );\n\t\t\t\t} else {\n\t\t\t\t\t// Field doesn't exist by id or by name\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tvalue = $formField.val();\n\t\t\tif ( rule.required ) {\n\t\t\t\tif ( isEmpty( fieldKey, value ) ) {\n\t\t\t\t\tfailed = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( rule.pattern && !isEmpty( fieldKey, value ) ) {\n\t\t\t\tif ( !value.match( new RegExp( rule.pattern ) ) ) {\n\t\t\t\t\tfailed = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( failed ) {\n\t\t\t\tsetError( fieldKey, rule.message );\n\t\t\t}\n\t\t} );\n\t} );\n\n\t// FIXME: wouldn't $( '#country' ).val() work for both types?\n\tcountryField = document.getElementById( 'country' );\n\tif ( countryField && countryField.type === 'select-one' ) { // country is a dropdown select\n\t\tif ( !$.trim( countryField.options[ countryField.selectedIndex ].value ) ) {\n\t\t\tsetError(\n\t\t\t\t'country',\n\t\t\t\tmediaWiki.msg( 'donate_interface-error-msg-country' )\n\t\t\t);\n\t\t} else {\n\t\t\tclearError( 'country' );\n\t\t}\n\t} else { // country is a hidden or text input\n\t\tif ( !$.trim( countryField.value ) ) {\n\t\t\tsetError(\n\t\t\t\t'country',\n\t\t\t\tmediaWiki.msg( 'donate_interface-error-msg-country' )\n\t\t\t);\n\t\t} else {\n\t\t\tclearError( 'country' );\n\t\t}\n\t}\n\n\t// validate email address\n\t// FIXME: replace with regex in wgDonationInterfaceValidationRules\n\temailAdd = document.getElementById( 'email' );\n\tif (\n\t\temailAdd &&\n\t\t$.trim( emailAdd.value ) &&\n\t\temailAdd.value !== mediaWiki.msg( 'donate_interface-donor-email' )\n\t) {\n\t\tinvalid = false;\n\n        var specialCharacterRegex = [ '(^[\\\\-])|',\n        '([`!@#$%^&*()_+\\\\-=\\\\[\\\\]{};\\':\"\\\\\\\\|,.<>\\\\/?~]+$)' ];\n\n        if ( new RegExp( specialCharacterRegex.join( '' ) ).test( emailAdd.value ) ) {\n            setError(\n                'email',\n                mediaWiki.msg( 'donate_interface-error-msg-invalid-email' )\n            );\n            invalid = true;\n        }\n\t\tapos = emailAdd.value.indexOf( '@' );\n\t\tdotpos = emailAdd.value.lastIndexOf( '.' );\n\n\t\tif ( apos < 1 || dotpos - apos < 2 ) {\n\t\t\tsetError(\n\t\t\t\t'email',\n\t\t\t\tmediaWiki.msg( 'donate_interface-error-msg-invalid-email' )\n\t\t\t);\n\t\t\tinvalid = true;\n\t\t}\n\n\t\tdomain = emailAdd.value.slice( Math.max( 0, apos + 1 ) );\n\n\t\tfor ( i = 0; i < invalids.length && !invalid; i++ ) {\n\t\t\tif ( domain.indexOf( invalids[ i ] ) !== -1 ) {\n\t\t\t\tsetError(\n\t\t\t\t\t'email',\n\t\t\t\t\tmediaWiki.msg( 'donate_interface-error-msg-invalid-email' )\n\t\t\t\t);\n\t\t\t\tinvalid = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif ( /[0-9]$/.test( domain ) ) {\n\t\t\tsetError(\n\t\t\t\t'email',\n\t\t\t\tmediaWiki.msg( 'donate_interface-error-msg-invalid-email' )\n\t\t\t);\n\t\t}\n\t}\n\n\t// Make sure cookies are enabled\n\tdocument.cookie = 'wmf_test=1;';\n\tif ( document.cookie.indexOf( 'wmf_test=1' ) !== -1 ) {\n\t\tdocument.cookie = 'wmf_test=; expires=Thu, 01-Jan-70 00:00:01 GMT;'; // unset the cookie\n\t\tclearError( 'cookie' );\n\t} else {\n\t\terrorsPresent = true; // display error\n\t\tsetError( 'cookie', mediaWiki.msg( 'donate_interface-error-msg-cookies' ) );\n\t}\n\n\treturn !errorsPresent;\n};\n","usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/package-lock.json","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"no-extra-parens","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/package.json","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"no-extra-parens","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]},{"filePath":"/src/repo/paypal_ec_gateway/forms/js/paypal.js","messages":[],"suppressedMessages":[],"errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":[{"ruleId":"array-bracket-spacing","replacedBy":[]},{"ruleId":"block-spacing","replacedBy":[]},{"ruleId":"brace-style","replacedBy":[]},{"ruleId":"comma-dangle","replacedBy":[]},{"ruleId":"comma-style","replacedBy":[]},{"ruleId":"computed-property-spacing","replacedBy":[]},{"ruleId":"dot-location","replacedBy":[]},{"ruleId":"eol-last","replacedBy":[]},{"ruleId":"func-call-spacing","replacedBy":[]},{"ruleId":"key-spacing","replacedBy":[]},{"ruleId":"keyword-spacing","replacedBy":[]},{"ruleId":"linebreak-style","replacedBy":[]},{"ruleId":"max-statements-per-line","replacedBy":[]},{"ruleId":"new-parens","replacedBy":[]},{"ruleId":"no-floating-decimal","replacedBy":[]},{"ruleId":"no-multiple-empty-lines","replacedBy":[]},{"ruleId":"no-new-object","replacedBy":["no-object-constructor"]},{"ruleId":"no-tabs","replacedBy":[]},{"ruleId":"no-trailing-spaces","replacedBy":[]},{"ruleId":"no-whitespace-before-property","replacedBy":[]},{"ruleId":"object-curly-spacing","replacedBy":[]},{"ruleId":"operator-linebreak","replacedBy":[]},{"ruleId":"quote-props","replacedBy":[]},{"ruleId":"quotes","replacedBy":[]},{"ruleId":"semi","replacedBy":[]},{"ruleId":"semi-spacing","replacedBy":[]},{"ruleId":"semi-style","replacedBy":[]},{"ruleId":"space-before-blocks","replacedBy":[]},{"ruleId":"space-before-function-paren","replacedBy":[]},{"ruleId":"space-in-parens","replacedBy":[]},{"ruleId":"space-infix-ops","replacedBy":[]},{"ruleId":"space-unary-ops","replacedBy":[]},{"ruleId":"switch-colon-spacing","replacedBy":[]},{"ruleId":"no-extra-semi","replacedBy":[]},{"ruleId":"no-mixed-spaces-and-tabs","replacedBy":[]}]}]

--- end ---
$ ./node_modules/.bin/banana-checker --autofix=true --requireLowerCase=false gateway_common/i18n/interface gateway_common/i18n/country-specific gateway_common/i18n/countries gateway_common/i18n/us-states gateway_common/i18n/canada-provinces gateway_common/i18n/api amazon_gateway/i18n adyen_gateway/i18n ingenico_gateway/i18n paypal_ec_gateway/i18n email_forms/i18n
--- stderr ---
The "ba" translation has 1 translation with trailing whitespace:
* donate_interface-taxded-msg-int
Loading source messages failed: "Error: Cannot find module '/src/repo/gateway_common/i18n/countries/en.json'
Require stack:
- /src/repo/node_modules/grunt-banana-checker/src/banana.js
- /src/repo/node_modules/grunt-banana-checker/src/cli.js".
/src/repo/node_modules/grunt-banana-checker/src/banana.js:111
			throw e;
			^

Error: Cannot find module '/src/repo/gateway_common/i18n/countries/en.json'
Require stack:
- /src/repo/node_modules/grunt-banana-checker/src/banana.js
- /src/repo/node_modules/grunt-banana-checker/src/cli.js
    at Module._resolveFilename (node:internal/modules/cjs/loader:1134:15)
    at Module._load (node:internal/modules/cjs/loader:975:27)
    at Module.require (node:internal/modules/cjs/loader:1225:19)
    at require (node:internal/modules/helpers:177:18)
    at messages (/src/repo/node_modules/grunt-banana-checker/src/banana.js:108:19)
    at bananaChecker (/src/repo/node_modules/grunt-banana-checker/src/banana.js:226:25)
    at /src/repo/node_modules/grunt-banana-checker/src/cli.js:90:11
    at Array.forEach (<anonymous>)
    at Object.<anonymous> (/src/repo/node_modules/grunt-banana-checker/src/cli.js:89:6)
    at Module._compile (node:internal/modules/cjs/loader:1356:14) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/src/repo/node_modules/grunt-banana-checker/src/banana.js',
    '/src/repo/node_modules/grunt-banana-checker/src/cli.js'
  ]
}

Node.js v18.19.0
--- stdout ---

--- end ---
$ ./node_modules/.bin/banana-checker --requireLowerCase=false gateway_common/i18n/interface gateway_common/i18n/country-specific gateway_common/i18n/countries gateway_common/i18n/us-states gateway_common/i18n/canada-provinces gateway_common/i18n/api amazon_gateway/i18n adyen_gateway/i18n ingenico_gateway/i18n paypal_ec_gateway/i18n email_forms/i18n
--- stderr ---
The "ba" translation has 1 translation with trailing whitespace:
* donate_interface-taxded-msg-int
Loading source messages failed: "Error: Cannot find module '/src/repo/gateway_common/i18n/countries/en.json'
Require stack:
- /src/repo/node_modules/grunt-banana-checker/src/banana.js
- /src/repo/node_modules/grunt-banana-checker/src/cli.js".
/src/repo/node_modules/grunt-banana-checker/src/banana.js:111
			throw e;
			^

Error: Cannot find module '/src/repo/gateway_common/i18n/countries/en.json'
Require stack:
- /src/repo/node_modules/grunt-banana-checker/src/banana.js
- /src/repo/node_modules/grunt-banana-checker/src/cli.js
    at Module._resolveFilename (node:internal/modules/cjs/loader:1134:15)
    at Module._load (node:internal/modules/cjs/loader:975:27)
    at Module.require (node:internal/modules/cjs/loader:1225:19)
    at require (node:internal/modules/helpers:177:18)
    at messages (/src/repo/node_modules/grunt-banana-checker/src/banana.js:108:19)
    at bananaChecker (/src/repo/node_modules/grunt-banana-checker/src/banana.js:226:25)
    at /src/repo/node_modules/grunt-banana-checker/src/cli.js:90:11
    at Array.forEach (<anonymous>)
    at Object.<anonymous> (/src/repo/node_modules/grunt-banana-checker/src/cli.js:89:6)
    at Module._compile (node:internal/modules/cjs/loader:1356:14) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/src/repo/node_modules/grunt-banana-checker/src/banana.js',
    '/src/repo/node_modules/grunt-banana-checker/src/cli.js'
  ]
}

Node.js v18.19.0
--- stdout ---

--- end ---
Traceback (most recent call last):
  File "/venv/lib/python3.11/site-packages/runner-0.1.0-py3.11.egg/runner/__init__.py", line 1789, in main
    libup.run(args.repo, args.output, args.branch)
  File "/venv/lib/python3.11/site-packages/runner-0.1.0-py3.11.egg/runner/__init__.py", line 1728, in run
    self.npm_upgrade(plan)
  File "/venv/lib/python3.11/site-packages/runner-0.1.0-py3.11.egg/runner/__init__.py", line 1191, in npm_upgrade
    hook(update)
  File "/venv/lib/python3.11/site-packages/runner-0.1.0-py3.11.egg/runner/__init__.py", line 1331, in _handle_banana_checker
    self.check_call(["./node_modules/.bin/banana-checker", *options, *folders])
  File "/venv/lib/python3.11/site-packages/runner-0.1.0-py3.11.egg/runner/shell2.py", line 59, in check_call
    res.check_returncode()
  File "/usr/lib/python3.11/subprocess.py", line 502, in check_returncode
    raise CalledProcessError(self.returncode, self.args, self.stdout,
subprocess.CalledProcessError: Command '['./node_modules/.bin/banana-checker', '--requireLowerCase=false', 'gateway_common/i18n/interface', 'gateway_common/i18n/country-specific', 'gateway_common/i18n/countries', 'gateway_common/i18n/us-states', 'gateway_common/i18n/canada-provinces', 'gateway_common/i18n/api', 'amazon_gateway/i18n', 'adyen_gateway/i18n', 'ingenico_gateway/i18n', 'paypal_ec_gateway/i18n', 'email_forms/i18n']' returned non-zero exit status 1.
Source code is licensed under the AGPL.