Changeset 1898906
- Timestamp:
- 06/26/2018 03:02:50 AM (8 years ago)
- Location:
- auto-currency-converter/trunk
- Files:
-
- 5 edited
-
auto-currency-converter.php (modified) (1 diff)
-
includes/Akky/Money/ExchangeRate.php (modified) (2 diffs)
-
includes/Akky/Money/WordPressCachableExchangeRate.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
tests/phpunit (modified) (1 prop)
Legend:
- Unmodified
- Added
- Removed
-
auto-currency-converter/trunk/auto-currency-converter.php
r1898899 r1898906 8 8 Text Domain: auto_currency_converter 9 9 Domain Path: /languages 10 Version: 1. 1.910 Version: 1.2.0 11 11 Author URI: http://akimoto.jp/blog/ 12 12 License: GPL2 -
auto-currency-converter/trunk/includes/Akky/Money/ExchangeRate.php
r1898899 r1898906 46 46 return $this->_cached[$from][$to]; 47 47 } 48 $url = "https://ratesapi.io/api/latest?base= USD&symbols=JPY";48 $url = "https://ratesapi.io/api/latest?base=$from&symbols=$to"; 49 49 // local phpunit test may fail by not setting up cert properly. pass it only when test 50 50 $options = []; … … 64 64 } 65 65 $decoded = json_decode($json, true); 66 $rate = $decoded['rates'][ 'JPY'];66 $rate = $decoded['rates'][strtoupper($to)]; 67 67 68 68 $this->_cached[$from][$to] = $rate; -
auto-currency-converter/trunk/includes/Akky/Money/WordPressCachableExchangeRate.php
r1898899 r1898906 62 62 return $this->_cached[$from][$to]; 63 63 } 64 $url = "https://ratesapi.io/api/latest?base= USD&symbols=JPY";64 $url = "https://ratesapi.io/api/latest?base=$from&symbols=$to"; 65 65 $response = wp_remote_get($url); 66 66 if (is_wp_error($response) … … 70 70 $json = $response['body']; 71 71 $decoded = json_decode($json, true); 72 $rate = $decoded['rates'][ 'JPY'];72 $rate = $decoded['rates'][strtoupper($to)]; 73 73 74 74 $this->_cached[$from][$to] = $rate; -
auto-currency-converter/trunk/readme.txt
r1898899 r1898906 1 1 === Auto Currency Converter === 2 2 Contributors: akky 3 Version 1. 1.93 Version 1.2.0 4 4 Tags: currency, money, exchange, Japan, yen, Japanese, USA, dollar, JPY, USD 5 5 Home: http://wordpress.org/extend/plugins/auto-currency-converter … … 57 57 58 58 == 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 59 63 60 64 = 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
-
Property
svn:ignore
set to
Note: See TracChangeset
for help on using the changeset viewer.