Plugin Directory

Changeset 1898906


Ignore:
Timestamp:
06/26/2018 03:02:50 AM (8 years ago)
Author:
akky
Message:

commit version 1.2.0

Location:
auto-currency-converter/trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • auto-currency-converter/trunk/auto-currency-converter.php

    r1898899 r1898906  
    88  Text Domain: auto_currency_converter
    99  Domain Path: /languages
    10   Version: 1.1.9
     10  Version: 1.2.0
    1111  Author URI: http://akimoto.jp/blog/
    1212  License: GPL2
  • auto-currency-converter/trunk/includes/Akky/Money/ExchangeRate.php

    r1898899 r1898906  
    4646            return $this->_cached[$from][$to];
    4747        }
    48         $url = "https://ratesapi.io/api/latest?base=USD&symbols=JPY";
     48        $url = "https://ratesapi.io/api/latest?base=$from&symbols=$to";
    4949        // local phpunit test may fail by not setting up cert properly. pass it only when test
    5050        $options = [];
     
    6464        }
    6565        $decoded = json_decode($json, true);
    66         $rate = $decoded['rates']['JPY'];
     66        $rate = $decoded['rates'][strtoupper($to)];
    6767
    6868        $this->_cached[$from][$to] = $rate;
  • auto-currency-converter/trunk/includes/Akky/Money/WordPressCachableExchangeRate.php

    r1898899 r1898906  
    6262            return $this->_cached[$from][$to];
    6363        }
    64         $url = "https://ratesapi.io/api/latest?base=USD&symbols=JPY";
     64        $url = "https://ratesapi.io/api/latest?base=$from&symbols=$to";
    6565        $response = wp_remote_get($url);
    6666        if (is_wp_error($response)
     
    7070        $json = $response['body'];
    7171        $decoded = json_decode($json, true);
    72         $rate = $decoded['rates']['JPY'];
     72        $rate = $decoded['rates'][strtoupper($to)];
    7373
    7474        $this->_cached[$from][$to] = $rate;
  • auto-currency-converter/trunk/readme.txt

    r1898899 r1898906  
    11=== Auto Currency Converter ===
    22Contributors: akky
    3 Version 1.1.9
     3Version 1.2.0
    44Tags: currency, money, exchange, Japan, yen, Japanese, USA, dollar, JPY, USD
    55Home: http://wordpress.org/extend/plugins/auto-currency-converter
     
    5757
    5858== Changelog ==
     59
     60= 1.2.0 =
     61* fix a bug with the new API. Japanese conversion was badly done on version 1.1.8/1.1.9
     62* tested with the latest WordPress version 4.9.6
    5963
    6064= 1.1.9 =
  • auto-currency-converter/trunk/tests/phpunit

    • Property svn:ignore set to
      .editorconfig
      .git
      .gitignore
      .travis.yml
      README.md
      bin
      composer.json
      composer.lock
      package.json
      phpunit.xml
      phpunit.xml.dist
      ruleset.xml
      test.sh
      tests
Note: See TracChangeset for help on using the changeset viewer.