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

fix: asset product info type #1310

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion include/roblox.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ interface ProductInfo {

interface AssetProductInfo extends ProductInfo {
/** Describes whether the asset is a User Product, Developer Product, or Game Pass */
ProductType: "User Product";
ProductType?: "Collectible Item" | "User Product";
Copy link
Contributor

@Dionysusnu Dionysusnu Oct 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this the right way to change the type? Looking at your screenshot, Collectible Item has a handful of other fields, like CanBeSoldInThisGame, CollectibleItemId and SaleLocation. (Though perhaps the first and last of those exist for other asset types too?)

/** If InfoType was Asset, this is the ID of the given asset. */
AssetId: number;
/** The [type of asset](https://developer.roblox.com/articles/Asset-types) (e.g. place, model, shirt). In TypeScript, you should compare this value to a member of the `AssetTypeId` const enum. */
Expand Down