How to I reuse this to work for other game passes?

Hi! So I have a script I paid someone to make and I cant seem to understand how it works since my scripting knowledge is limited to Variables, Functions, Values and Moving Objects.

How it works

So, when someone purchases a gamepass, this script gives it to the player whenever they click the purchase option again.

The Script
local GamePassManager = {}

local MarketPlace = game:GetService(“MarketplaceService”)
local function CheckPass(Player, GamePass)
if MarketPlace:UserOwnsGamePassAsync(Player.UserId, GamePass) then
return true
else
return false
end
end

function GamePassManager.GivePassPort(Player)
local Passport = game.ReplicatedStorage.PassPort:Clone()
Passport.Name = Player.Name…“'s Passport”
Passport.Parent = Player.Backpack
end

function GamePassManager.GetGamePass(GamePass, Player)
pcall(function()
MarketPlace:PromptGamePassPurchase(Player, GamePass)
end)
MarketPlace.PromptGamePassPurchaseFinished:Wait()
local bool = CheckPass(Player, GamePass)
if bool == false then
return false
elseif bool == true then
return true
end
end
return GamePassManager

Script pt 2
local remote = game.ReplicatedStorage.Prompt

local GamePassManager = require(game.ServerStorage.GamePassManager)

remote.OnServerEvent:Connect(function(Player, PassId)

local bool = GamePassManager.GetGamePass(PassId, Player)

if bool == true then

GamePassManager.GivePassPort(Player)

end

end)

What i want to know
I have many other gamepasses I wish to use so I need to know how I can use these scripts multiple times to work for other gamepasses by giving an item upon purchase

NOTE
The tool it gives is stored in replicated storage.

Please comment if you have a solution!

Seems to me like gamepass ID’s are stored on the client, and are passed to the server via a remote to trigger the prompt.

If you want this to work with other gamepasses, just pass the gamepass ID you want to use into the PassId argument when you fire the remote client side.

Of course, you need to have a way to store these gamepass ID’s, and pick the appropriate one to use as the argument based on which pass icon you clicked. ( Or however you are choosing the gamepass as a player. )