Adds an explicit function for import file validation acceptability.
git-svn-id: file:///home/svn/framework3/trunk@9636 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
2949ef2458
commit
03918eeeda
|
@ -1380,6 +1380,16 @@ class DBManager
|
||||||
raise DBImportError.new("Could not automatically determine file type")
|
raise DBImportError.new("Could not automatically determine file type")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Boils down the validate_import_file to a boolean
|
||||||
|
def validate_import_file(data)
|
||||||
|
begin
|
||||||
|
import_filetype_detect(data)
|
||||||
|
rescue DBImportError
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
|
||||||
#
|
#
|
||||||
# Nexpose Simple XML
|
# Nexpose Simple XML
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in New Issue