Skip to content

Commit 0e094bf

Browse files
Merge pull request datashield#368 from datashield/revert-367-v6.1.2-dev
Revert "Fixed 'datasource' test"
2 parents 2c142e9 + 80223b8 commit 0e094bf

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

R/ds.scatterPlot.R

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,11 @@ ds.scatterPlot <- function (x=NULL, y=NULL, method='deterministic', k=3, noise=0
133133
stop("Please provide the name of the x-variable", call.=FALSE)
134134
}
135135

136+
# ensure datasources is a list of DSConnection-class
137+
if(!(is.list(datasources) && all(unlist(lapply(datasources, function(d) {methods::is(d,"DSConnection")}))))){
138+
stop("The 'datasources' were expected to be a list of DSConnection-class objects", call.=FALSE)
139+
}
140+
136141
if(is.null(y)){
137142
stop("Please provide the name of the y-variable", call.=FALSE)
138143
}
@@ -142,11 +147,6 @@ ds.scatterPlot <- function (x=NULL, y=NULL, method='deterministic', k=3, noise=0
142147
datasources <- datashield.connections_find()
143148
}
144149

145-
# ensure datasources is a list of DSConnection-class
146-
if(!(is.list(datasources) && all(unlist(lapply(datasources, function(d) {methods::is(d,"DSConnection")}))))){
147-
stop("The 'datasources' were expected to be a list of DSConnection-class objects", call.=FALSE)
148-
}
149-
150150
# the input variable might be given as column table (i.e. D$object)
151151
# or just as a vector not attached to a table (i.e. object)
152152
# we have to make sure the function deals with each case

0 commit comments

Comments
 (0)