anchor.diff:                                   false ->
                                        {SeenAcc1, StateAcc1} = maybe_lock(Profile, AppInfo, SeenAcc, StateAcc, Level),
                                        {SrcDepsAcc1, PkgDepsAcc1, SrcAppsAcc1, StateAcc2, LocksAcc1} =
  -                                         case Update of
  +                                         case Upgrade of
                                                true ->
  -                                             %{true, UpdateName, UpdateLevel} ->
  -                                                 handle_update(AppInfo
  +                                             %{true, UpgradeName, UpgradeLevel} ->
  +                                                 handle_upgrade(AppInfo
                                                                 ,SrcDepsAcc
                                                                 ,PkgDepsAcc
                                                                 ,SrcAppsAcc
  
positive.code:                                            [warn_skip_pkg(Pkg) || Pkg <- Discarded],
                                             Solution
                                     end,
                                 update_pkg_deps(Profile, S, Packages, Update, Seen, State1)
                         end,
  
      AllDeps = lists:ukeymerge(2
  
negative.code:     end.
  
  -spec update_src_deps(atom(), non_neg_integer(), list(), list(), list(), rebar_state:t(), boolean(), sets:set(binary()), list()) -> {rebar_state:t(), list(), list(), sets:set(binary())}.
  update_src_deps(Profile, Level, SrcDeps, PkgDeps, SrcApps, State, Upgrade, Seen, Locks) ->
      case lists:foldl(fun(AppInfo, {SrcDepsAcc, PkgDepsAcc, SrcAppsAcc, StateAcc, SeenAcc, LocksAcc}) ->
                               %% If not seen, add to list of locks to write out
                               Name = rebar_app_info:name(AppInfo),
  