diff --git a/app/Ninja/Datatables/AccountGatewayDatatable.php b/app/Ninja/Datatables/AccountGatewayDatatable.php index ad16fc39878a..fe6a8df0df7a 100644 --- a/app/Ninja/Datatables/AccountGatewayDatatable.php +++ b/app/Ninja/Datatables/AccountGatewayDatatable.php @@ -29,18 +29,13 @@ class AccountGatewayDatatable extends EntityDatatable $wepayState = isset($config->state)?$config->state:null; $linkText = $model->name; $url = $endpoint.'account/'.$wepayAccountId; - $wepay = \Utils::setupWepay($accountGateway); $html = link_to($url, $linkText, array('target'=>'_blank'))->toHtml(); try { if ($wepayState == 'action_required') { - $updateUri = $wepay->request('/account/get_update_uri', array( - 'account_id' => $wepayAccountId, - 'redirect_uri' => URL::to('gateways'), - )); - + $updateUri = $endpoint.'api/account_update/'.$wepayAccountId.'?redirect_uri='.urlencode(URL::to('gateways')); $linkText .= ' ('.trans('texts.action_required').')'; - $url = $updateUri->uri; + $url = $updateUri; $html = "{$linkText}"; $model->setupUrl = $url; } elseif ($wepayState == 'pending') {