Skip to content

Commit b86224c

Browse files
authored
Debug test failures (#159)
1 parent e72f048 commit b86224c

1 file changed

Lines changed: 2 additions & 10 deletions

File tree

R/Utils.R

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -210,21 +210,13 @@ SetAssayData4Or5 <- function(seuratObj, theLayer, new.data, ...) {
210210
new.data <- Seurat::as.sparse(as.matrix(new.data))
211211
}
212212

213-
if (!seuratObj@version < '5.0.0') {
214-
return(Seurat::SetAssayData(seuratObj, slot = theLayer, new.data = new.data, ...))
215-
} else {
216-
return(Seurat::SetAssayData(seuratObj, layer = theLayer, new.data = new.data, ...))
217-
}
213+
return(Seurat::SetAssayData(seuratObj, layer = theLayer, new.data = new.data, ...))
218214
}
219215

220216
GetAssayData4Or5 <- function(seuratObj, theLayer, ...) {
221217
if (! theLayer %in% SeuratObject::Layers(Seurat::GetAssay(seuratObj))) {
222218
stop(paste0('Unknown layer: ', theLayer))
223219
}
224220

225-
if (!seuratObj@version < '5.0.0') {
226-
return(Seurat::GetAssayData(seuratObj, slot = theLayer, ...))
227-
} else {
228-
return(Seurat::GetAssayData(seuratObj, layer = theLayer, ...))
229-
}
221+
return(Seurat::GetAssayData(seuratObj, layer = theLayer, ...))
230222
}

0 commit comments

Comments
 (0)