mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-12-23 00:43:48 +01:00
LSldapObject :: _cli_remove : use LScli :: confirm
This commit is contained in:
parent
1de6d1d25e
commit
3d9c11e12f
1 changed files with 3 additions and 9 deletions
|
@ -2041,16 +2041,10 @@ class LSldapObject extends LSlog_staticLoggerClass {
|
|||
}
|
||||
|
||||
if ($confirm) {
|
||||
echo $obj -> _cli_show($raw_values);
|
||||
$obj -> _cli_show($raw_values);
|
||||
// Sure ?
|
||||
echo "\nAre you sure you want to delete this object ? Type 'yes' to continue: ";
|
||||
$handle = fopen ("php://stdin","r");
|
||||
$line = fgets($handle);
|
||||
if(trim($line) != 'yes'){
|
||||
echo "User cancel\n";
|
||||
return True;
|
||||
}
|
||||
echo "\n";
|
||||
if (!LScli :: confirm("\nAre you sure you want to delete this object?"));
|
||||
return True;
|
||||
}
|
||||
|
||||
if ($obj -> remove()) {
|
||||
|
|
Loading…
Reference in a new issue