Skip to content

Commit

Permalink
Framework bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
gdr1461 authored Jul 4, 2024
1 parent 9cda7b9 commit d238553
Showing 1 changed file with 17 additions and 5 deletions.
22 changes: 17 additions & 5 deletions Source/.MainModule/Client/Modules/Framework.lua
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,8 @@ function Framework:Configure()
if not Opened then
return
end

self:ResetMainFrame()
self:CurrentFrame()
end)

--== SETTING UP USER RANK UPDATE ==--
Expand Down Expand Up @@ -623,10 +623,22 @@ function Framework:NewCmdBar()
AutoFill.Parent = Data.CmdBar

for i, Command in ipairs(Similar) do
local CommandSettings = GlobalAPI:FindValueParent(Commands.Commands, Command)
CommandSettings = CommandSettings or {
Arguments = {},
References = {}
}

local RawArguments = CommandSettings.References or CommandSettings.Arguments
for i, Argument in ipairs(RawArguments) do
RawArguments[i] = `[{Argument:gsub("%p", "")}]`
end

local Arguments = table.concat(RawArguments, " ")
local Template = script.AutoFill.Fill:Clone()
Template.Name = Command

Template.Title.Text = Command
Template.Name = Command
Template.Title.Text = `{Command}{Arguments ~= "" and ` {Arguments}` or ""}`
Template.Parent = AutoFill

AutoFills[i] = Template
Expand Down Expand Up @@ -719,8 +731,8 @@ function Framework:OpenFrame(Frame, Page)

self.__Current = Frame.Name
local Pages = Frame:FindFirstChild("Pages")

Page = Page or 1

if Pages and Page then
self.__CurrentPage = Page
Pages[tostring(Page, 10)].Visible = true
Expand Down

0 comments on commit d238553

Please sign in to comment.