File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 2525
2626 // get the keys and normalize to lowercase
2727 $ originalContentKeys = array_keys ($ contentFields );
28- $ contentFieldKeys = array_map ('mb_strtolower ' , $ originalContentKeys );
28+ $ contentFieldKeys = array_map ('mb_strtolower ' , $ originalContentKeys );
2929
3030 // get all field keys from blueprint and normalize to lowercase
31- $ blueprintFields = array_keys ($ item ->blueprint ()->fields ());
31+ $ blueprintFields = array_keys ($ item ->blueprint ()->fields ());
3232 $ blueprintFieldKeys = array_map ('mb_strtolower ' , $ blueprintFields );
3333
3434 // get all field keys that are in $contentFieldKeys but not in $blueprintFieldKeys
5353 }
5454
5555 // don't update models that have changes
56- if ($ item ->version ('changes ' )->exists () === true ) {
56+ if ($ item ->version ('changes ' )->exists ($ lang ) === true ) {
5757 $ cli ->error ('The ' . $ item ::CLASS_ALIAS . ' ( ' . $ item ->id () . ') has changes and cannot be cleaned. Save the changes and try again. ' );
5858 }
5959
6868 // check if the version exists for the given language
6969 // and try to update the page with the data
7070 if ($ version ->exists ($ lang ) === true ) {
71- $ version ->update ($ data );
71+ $ version ->update ($ data, $ lang );
7272 }
7373 }
7474};
You can’t perform that action at this time.
0 commit comments