in src/schema/browser-apis.js [152:183]
export function isDeprecatedApi(
namespace,
property,
addonMetadata,
apiSchemas = schemas
) {
// If the API has been removed in a certain manifest version, or only
// available starting from a manifest version, then it is unsupported
// and not deprecated.
if (
!isInSupportedManifestVersionRange(
namespace,
property,
addonMetadata,
apiSchemas
)
) {
return false;
}
const schema = apiSchemas[namespace];
const schemaItem =
getObjectProperty(schema, property) || getArrayProperty(schema, property);
return (
(schemaItem !== null && schemaItem.deprecated !== undefined) ||
Object.prototype.hasOwnProperty.call(
DEPRECATED_JAVASCRIPT_APIS,
`${namespace}.${property}`
)
);
}