Skip to content

Commit

Permalink
Fix manual table clone
Browse files Browse the repository at this point in the history
  • Loading branch information
LastTalon committed Jan 8, 2024
1 parent 051ad43 commit ad1f6c8
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/Style.lua
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,7 @@ end
]=]
function Style.set(styleFragment)
local existing = Runtime.useContext(ContextKey) or defaultStyle
local newStyle = {}

for key, value in pairs(existing) do
newStyle[key] = value
end
local newStyle = table.clone(existing)

for key, value in pairs(styleFragment) do
newStyle[key] = value
Expand Down

0 comments on commit ad1f6c8

Please sign in to comment.