diff --git a/src/zabapgit_objects_impl.prog.abap b/src/zabapgit_objects_impl.prog.abap index ee79b7b5a..a05aef75f 100644 --- a/src/zabapgit_objects_impl.prog.abap +++ b/src/zabapgit_objects_impl.prog.abap @@ -13,38 +13,17 @@ CLASS lcl_objects IMPLEMENTATION. DATA: lv_index TYPE i, lv_answer TYPE c, - lv_question TYPE string, - lt_before TYPE lcl_persistence_repo=>ty_local_checksum_tt, - lt_current TYPE lcl_persistence_repo=>ty_local_checksum_tt. + lv_question TYPE string. - FIELD-SYMBOLS: LIKE LINE OF lt_before, - LIKE LINE OF lt_current, - LIKE LINE OF ct_results. + FIELD-SYMBOLS: LIKE LINE OF ct_results. - lt_before = io_repo->get_local_checksums( ). - lt_current = io_repo->build_local_checksums( ). - LOOP AT ct_results ASSIGNING . lv_index = sy-tabix. - READ TABLE lt_before ASSIGNING - WITH KEY item-obj_type = -obj_type - item-obj_name = -obj_name. - IF sy-subrc <> 0. - CONTINUE. - ENDIF. - - READ TABLE lt_current ASSIGNING - WITH KEY item-obj_type = -obj_type - item-obj_name = -obj_name. - IF sy-subrc <> 0. - CONTINUE. - ENDIF. - - IF -sha1 <> -sha1. - lv_question = |It looks like object { -obj_type - } { -obj_name + IF -lstate IS NOT INITIAL. " Modified ? + lv_question = |It looks like object { + -obj_type } { -obj_name } has been modified locally, overwrite object?|. lv_answer = lcl_popups=>popup_to_confirm( @@ -628,7 +607,9 @@ CLASS lcl_objects IMPLEMENTATION. lt_remote = io_repo->get_files_remote( ). lt_results = lcl_file_status=>status( io_repo ). - DELETE lt_results WHERE match = abap_true. + DELETE lt_results WHERE + match = abap_true " Full match + OR rstate IS INITIAL. " no remote changes, only local SORT lt_results BY obj_type ASCENDING obj_name ASCENDING. DELETE ADJACENT DUPLICATES FROM lt_results COMPARING obj_type obj_name.