When I have ongoing changes at dev branch, and something breaks in production environment, then I switch to master, fix the problem and synchronize the production environment with the master branch.
Now I return to dev branch. This branch is synchronized with test and staging environment.
What is the proper way to bring to dev branch that fix from master?
Currently I do git merge master when at dev branch.
But when merging like that, I noticed a new commit is created staging the modified files from master.
I was under the impression when merging that the commits created at master when applying the fix would just be inserted into the dev branch.
 
    