Skip to content
Snippets Groups Projects
Commit d1e7e116 authored by Johannes Boog's avatar Johannes Boog
Browse files

[bugfix] passing of wrong string object when reading prj file

parent 21e53f50
No related branches found
No related tags found
1 merge request!54[bugfix] make all OGS6 benchmarks work.
...@@ -177,15 +177,15 @@ node_to_object <- function(xml_node, ...@@ -177,15 +177,15 @@ node_to_object <- function(xml_node,
xml_attrs <- xml2::xml_attrs(xml_node) xml_attrs <- xml2::xml_attrs(xml_node)
xml_text <- xml2::xml_text(xml_node) xml_text <- xml2::xml_text(xml_node)
xml_text_clean <- stringr::str_trim(xml_text)
xml_text_clean <- xml_text_clean <-
stringr::str_remove_all(xml_text, "[\n|[:space:]]") stringr::str_remove_all(xml_text_clean, "[\n]")
if(xml_text_clean != "" && length(xml_attrs) != 0){ if(xml_text_clean != "" && length(xml_attrs) != 0){
return(invisible(c(xml_attrs, xml_text = xml_text))) return(invisible(c(xml_attrs, xml_text = xml_text_clean)))
} }
else if(xml_text_clean != ""){ else if(xml_text_clean != ""){
return(invisible(xml_text)) return(invisible(xml_text_clean))
} }
else if(length(xml_attrs) != 0){ else if(length(xml_attrs) != 0){
return(invisible(xml_attrs)) return(invisible(xml_attrs))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment