02088b Fix giving a project to someone who already had it

Authored and Committed by Pierre-Yves Chibon 5 years ago
    Fix giving a project to someone who already had it
    
    Basically, if you give a project to someone else, they get added to the
    project. If you then take it over from them somehow (say on src.fp.o by
    taking it from the "orphan" user), you're being added again and this
    used to fail as pagure would say that you already have access.
    So we're splitting the action into two:
    1/ give the project to the person it should be going to
    2/ give that person access to the project.
    
    So if the step 2/ fails because the person already has access, at least
    the first step will have succeeded.
    
    Signed-off-by: Pierre-Yves Chibon <pingou@pingoured.fr></pingou@pingoured.fr>
    
        
file modified
+32 -13