Skip to content

Commit

Permalink
fix: urlslab incorrect credits
Browse files Browse the repository at this point in the history
  • Loading branch information
vzeman committed Sep 24, 2024
1 parent d1ae69b commit db50d05
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion includes/api/class-urlslab-api-billing.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ private function read_arguments( string $method_name ) {

public function get_credits( WP_REST_Request $request ) {
try {
$credit = $this->get_client()->getCreditBalance();
$credit = $this->get_client()->getWorkspaceCreditBalance(Urlslab_Connection_FlowHunt::get_workspace_id());
Urlslab_User_Widget::get_instance()->get_widget( Urlslab_Widget_General::SLUG )->update_option( Urlslab_Widget_General::SETTING_NAME_FLOWHUNT_CREDITS, $credit->getCredits() );
$credit['credits'] = round( $credit['credits'] / 1000000, 2 );

Expand Down

0 comments on commit db50d05

Please sign in to comment.