Skip to content

[Bug]: dropins_mu_plugins in SystemStatus should be an object, not an array #5

Description

@SzymonZasada

📝 Description

In SystemStatus, dropins_mu_plugins is specified as an array, but WooCommerce
returns an object there, so GET /system_status can't be deserialized.

WooCommerce's get_dropins_mu_plugins() always returns:

array(
    'dropins'    => array(),
    'mu_plugins' => array(),
)

com.google.gson.JsonSyntaxException: java.lang.IllegalStateException:
Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 5755 path $.dropins_mu_plugins

📌 Affected Specification Version

latest

❓ Issue Type

Incorrect Schema Definition

✅ Expected Behavior

use object instead of list

❌ Current Behavior

com.google.gson.JsonSyntaxException: java.lang.IllegalStateException:
Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 5755 path $.dropins_mu_plugins for java api client

🔄 Steps to Reproduce

No response

🛠️ Suggested Fix (if any)

change spec to:

dropins_mu_plugins:
type: object
description: Dropins and MU plugins.

ℹ️ Additional Info

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions