Skip to content

Commit

Permalink
rename: singularize add_{upload,seek}_callback
Browse files Browse the repository at this point in the history
These only add one callback so having them be plural is weird.
  • Loading branch information
StefanKarpinski committed Dec 14, 2021
1 parent ab628ab commit 5bd0826
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Curl/Easy.jl
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ function set_upload_size(easy::Easy, size::Integer)
end

function set_seeker(seeker::Function, easy::Easy)
add_seek_callbacks(easy)
add_seek_callback(easy)
easy.seeker = seeker
end

Expand Down Expand Up @@ -159,7 +159,7 @@ function enable_progress(easy::Easy, on::Bool=true)
end

function enable_upload(easy::Easy)
add_upload_callbacks(easy::Easy)
add_upload_callback(easy::Easy)
setopt(easy, CURLOPT_UPLOAD, true)
end

Expand Down Expand Up @@ -404,7 +404,7 @@ function add_callbacks(easy::Easy)
setopt(easy, CURLOPT_XFERINFODATA, easy_p)
end

function add_upload_callbacks(easy::Easy)
function add_upload_callback(easy::Easy)
# pointer to easy object
easy_p = pointer_from_objref(easy)

Expand All @@ -415,7 +415,7 @@ function add_upload_callbacks(easy::Easy)
setopt(easy, CURLOPT_READDATA, easy_p)
end

function add_seek_callbacks(easy::Easy)
function add_seek_callback(easy::Easy)
# pointer to easy object
easy_p = pointer_from_objref(easy)

Expand Down

0 comments on commit 5bd0826

Please sign in to comment.