This repository was archived by the owner on Apr 29, 2019. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -123,14 +123,14 @@ public function import(array $data)
123
123
if ($ this ->scopeConfig instanceof Config) {
124
124
$ this ->scopeConfig ->clean ();
125
125
}
126
-
127
126
$ this ->state ->emulateAreaCode (Area::AREA_ADMINHTML , function () use ($ changedData , $ data ) {
128
127
$ this ->scope ->setCurrentScope (Area::AREA_ADMINHTML );
129
128
130
129
// Invoke saving of new values.
131
130
$ this ->saveProcessor ->process ($ changedData );
132
- $ this ->flagManager ->saveFlag (static ::FLAG_CODE , $ data );
133
131
});
132
+ $ this ->scope ->setCurrentScope ($ currentScope );
133
+ $ this ->flagManager ->saveFlag (static ::FLAG_CODE , $ data );
134
134
} catch (\Exception $ e ) {
135
135
throw new InvalidTransitionException (__ ('%1 ' , $ e ->getMessage ()), $ e );
136
136
} finally {
Original file line number Diff line number Diff line change @@ -156,6 +156,9 @@ public function testImport()
156
156
$ this ->scopeMock ->expects ($ this ->at (2 ))
157
157
->method ('setCurrentScope ' )
158
158
->with ('oldScope ' );
159
+ $ this ->scopeMock ->expects ($ this ->at (3 ))
160
+ ->method ('setCurrentScope ' )
161
+ ->with ('oldScope ' );
159
162
$ this ->flagManagerMock ->expects ($ this ->once ())
160
163
->method ('saveFlag ' )
161
164
->with (Importer::FLAG_CODE , $ data );
You can’t perform that action at this time.
0 commit comments