Skip to content

Commit

Permalink
fixfixfix
Browse files Browse the repository at this point in the history
Signed-off-by: Allen Faure <[email protected]>
  • Loading branch information
emptyrivers committed Jan 30, 2024
1 parent 3db3cd0 commit 8e93f6b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions WeakAuras/Features.lua
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ end

-- enable persisted features from the db
function Features:Hydrate()
for id, enabled in (Private.db.features) do
for id, enabled in pairs(Private.db.features) do
if not self:Exists(id) then
Private.db.features[id] = nil
end
Expand All @@ -68,7 +68,7 @@ function Features:Register(feature)
self.__feats[feature.id] = feature
feature.sub = Private.CreateSubscribableObject()
for _, buildType in ipairs(feature.autoEnable or {}) do
if Private.buildType == buildType then
if WeakAuras.buildType == buildType then
self:Enable(feature.id)
end
end
Expand Down Expand Up @@ -109,9 +109,8 @@ function Features:Subscribe(id, callback)
end
end

-- sample debug feature

Features:Register({
id = "debug",
autoEnable = {"dev"}
})

2 changes: 1 addition & 1 deletion WeakAuras/Init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ WeakAuras.buildType = "pr"
if versionStringFromToc == "@project-version@" then
versionStringFromToc = "Dev"
buildTime = "Dev"
WeakAuras.BuildType = "dev"
WeakAuras.buildType = "dev"
end
--@end-debug@

Expand Down

0 comments on commit 8e93f6b

Please sign in to comment.