Skip to content

Commit

Permalink
fix DataFrame extension for Julia 1.6
Browse files Browse the repository at this point in the history
  • Loading branch information
Helmut Hänsel committed May 3, 2024
1 parent 6b3367c commit e49f302
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions ext/StippleUIDataFramesExt.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
module StippleUIDataFramesExt

@static if isdefined(Base, :get_extension)
using DataFrames
using StippleUI
using StippleUI.Stipple
end
using StippleUI
using StippleUI.Stipple

isdefined(Base, :get_extension) ? (using DataFrames) : (using ..DataFrames)

function StippleUI.Tables.DataTable()
DataTable(DataFrames.DataFrame())
Expand Down
2 changes: 1 addition & 1 deletion src/StippleUI.jl
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ function __init__()
@static if !isdefined(Base, :get_extension)
@require DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" begin
# evaluate the code of the extension without the surrounding module
include(joinpath(@__DIR__, "..", "ext", "StippleUIDataFrames.jl"))
include(joinpath(@__DIR__, "..", "ext", "StippleUIDataFramesExt.jl"))
end
end
end
Expand Down

0 comments on commit e49f302

Please sign in to comment.