Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Function addorder mistake #6

Open
karik741 opened this issue Feb 27, 2018 · 1 comment
Open

Function addorder mistake #6

karik741 opened this issue Feb 27, 2018 · 1 comment

Comments

@karik741
Copy link
Contributor

karik741 commented Feb 27, 2018

public function addOrder($currency, $amount, $rate = null, $params = []) {
         $optional['symbol'] = $currency; // NOT OPTIONAL - $PARAMS
         $optional['quantity'] = $amount;  // NOT OPTIONAL - $PARAMS
         if (empty($params['type'])) $params['type'] = 'market';
         if (!empty($rate)) $params['price'] = $rate;

         return $this->request('order', $optional['clientOrderId'] ? 'order/' . $optional['clientOrderId'] : null, $params, 'POST');
    }
@karik741 karik741 changed the title function addorder Function addorder mistake Feb 27, 2018
@dzarezenko
Copy link
Owner

Hi,
if you have some suggestions on code improvements or bug fixes - make pull request please.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants