summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndriy Sharandakov <ash.ashway@gmail.com>2016-04-05 18:23:05 -0400
committerAndriy Sharandakov <ash.ashway@gmail.com>2016-04-05 18:23:05 -0400
commitf2f391c54df1c4e9925f982ba54f069c24409dc1 (patch)
tree2e1a630fbf675d77d61c777fb5f34d0c58a87b7a
parent4a1336e40ad9eb651661d18ce6a3153e979507aa (diff)
downloadphpvirtualbox-f2f391c54df1c4e9925f982ba54f069c24409dc1.zip
phpvirtualbox-f2f391c54df1c4e9925f982ba54f069c24409dc1.tar.gz
phpvirtualbox-f2f391c54df1c4e9925f982ba54f069c24409dc1.tar.bz2
Fixed invalid new HDD path issue when enforceVMOwnership is enabled
-rw-r--r--panes/wizardNewHD.html2
-rw-r--r--panes/wizardNewHDAdvanced.html2
2 files changed, 2 insertions, 2 deletions
diff --git a/panes/wizardNewHD.html b/panes/wizardNewHD.html
index f79de40..6e9883c 100644
--- a/panes/wizardNewHD.html
+++ b/panes/wizardNewHD.html
@@ -269,7 +269,7 @@ $('#wizardNewHDStep1').on('show',function(e,wiz){
$('#wizardNewHDSize').slider('value',wiz.suggested.size);
}
- if(wiz.suggested.path){
+ if(wiz.suggested.path && wiz.suggested.name){
if($('#vboxPane').data('vboxConfig').enforceVMOwnership==true){
var nameIndex = wiz.suggested.path.lastIndexOf(wiz.suggested.name+$('#vboxPane').data('vboxConfig').DSEP);
var path = wiz.suggested.path.substr(0,nameIndex);
diff --git a/panes/wizardNewHDAdvanced.html b/panes/wizardNewHDAdvanced.html
index 0fbc46a..408fe80 100644
--- a/panes/wizardNewHDAdvanced.html
+++ b/panes/wizardNewHDAdvanced.html
@@ -229,7 +229,7 @@ $('#wizardNewHDStep1').on('show',function(e,wiz){
$('#wizardNewHDSize').slider('value',wiz.suggested.size);
}
- if(wiz.suggested.path){
+ if(wiz.suggested.path && wiz.suggested.name){
if($('#vboxPane').data('vboxConfig').enforceVMOwnership==true){
var nameIndex = wiz.suggested.path.lastIndexOf(wiz.suggested.name+$('#vboxPane').data('vboxConfig').DSEP);
var path = wiz.suggested.path.substr(0,nameIndex);