1 // Copyright (c) 2022 Samsung Electronics Co., Ltd All Rights Reserved
2 // Use of this source code is governed by a apache 2.0 license that can be
3 // found in the LICENSE file.
5 #include "wgt/step/filesystem/step_restore_wgt_symbolic_link.h"
7 #include "wgt/step/filesystem/step_create_wgt_symbolic_link.h"
10 namespace filesystem {
12 common_installer::Step::Status StepRestoreWgtSymbolicLink::undo() {
13 StepCreateWgtSymbolicLink step(context_);
15 Status result = step.precheck();
16 if (result != Status::OK) {
17 LOG(ERROR) << "Fail to execute precheck of CreateWgtSymbolicLink";
21 result = step.process();
22 if (result != Status::OK) {
23 LOG(ERROR) << "Fail to execute process of CreateWgtSymbolicLink";
30 } // namespace filesystem