Skip to content

Commit 6eb1837

Browse files
committed
More specific function signatures, cleanup on warns
1 parent 3cf6a20 commit 6eb1837

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/CloudGraphsDFG/services/CloudGraphsDFG.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -670,7 +670,7 @@ function getDataEntry(dfg::CloudGraphsDFG, label::Symbol, key::Symbol; currentTr
670670
properties)
671671
end
672672

673-
function addDataEntry!(dfg::CloudGraphsDFG, label::Symbol, bde::AbstractDataEntry; currentTransaction::Union{Nothing, Neo4j.Transaction}=nothing)
673+
function addDataEntry!(dfg::CloudGraphsDFG, label::Symbol, bde::BlobStoreEntry; currentTransaction::Union{Nothing, Neo4j.Transaction}=nothing)
674674
if bde.label in listDataEntries(dfg, label, currentTransaction=currentTransaction)
675675
error("Data label '$(bde.label)' already exists")
676676
end
@@ -686,7 +686,7 @@ function addDataEntry!(dfg::CloudGraphsDFG, label::Symbol, bde::AbstractDataEntr
686686
packed)
687687
end
688688

689-
function updateDataEntry!(dfg::CloudGraphsDFG, label::Symbol, bde::AbstractDataEntry; currentTransaction::Union{Nothing, Neo4j.Transaction}=nothing)
689+
function updateDataEntry!(dfg::CloudGraphsDFG, label::Symbol, bde::BlobStoreEntry; currentTransaction::Union{Nothing, Neo4j.Transaction}=nothing)
690690
if !(bde.label in listDataEntries(dfg, label, currentTransaction=currentTransaction))
691691
@warn "Data label '$(bde.label)' does not exist, adding"
692692
end

src/DataBlobs/services/BlobStores.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,9 @@ function addDataBlob!(store::FolderStore{T}, entry::BlobStoreEntry, data::T) whe
160160
blobfilename = joinpath(store.folder,"$(entry.id).dat")
161161
entryfilename = joinpath(store.folder,"$(entry.id).json")
162162
if isfile(blobfilename)
163-
error("Key '$(id)' blob already exists.")
163+
error("Key '$(entry.id)' blob already exists.")
164164
elseif isfile(entryfilename)
165-
error("Key '$(id)' entry already exists, but no blob.")
165+
error("Key '$(entry.id)' entry already exists, but no blob.")
166166
else
167167
open(blobfilename, "w") do f
168168
write(f, data)
@@ -178,9 +178,9 @@ function updateDataBlob!(store::FolderStore{T}, entry::BlobStoreEntry, data::T)
178178
blobfilename = joinpath(store.folder,"$(entry.id).dat")
179179
entryfilename = joinpath(store.folder,"$(entry.id).json")
180180
if !isfile(blobfilename)
181-
warn("Key '$(id)' doesn't exist.")
181+
@warn "Key '$(entry.id)' doesn't exist."
182182
elseif !isfile(entryfilename)
183-
warn("Key '$(id)' doesn't exist.")
183+
@warn "Key '$(entry.id)' doesn't exist."
184184
else
185185
open(blobfilename, "w") do f
186186
write(f, data)

0 commit comments

Comments
 (0)