[3671] code refactor after merge