Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1110,7 +1110,15 @@ private static String hashuid(FnCall fn) {
String removeUID = "@remove()";
try {
if (fn.args.length < 2) return fn.getArgs();
String prefix = getParam(fn);

//use prefix of anonymizer parameter, or from dicom tag
String prefix = "";
if(fn.args[0].startsWith("@")) {
prefix = getParam(fn);
} else {
prefix = fn.context.contentsNull(fn.args[0], fn.thisTag);
}

String uid = fn.context.contentsNull(fn.args[1], fn.thisTag);
//If there is no UID in the dataset, then return @remove().
if (uid == null) return removeUID;
Expand Down