Might be useful for someone. My tailgate handle started misbehaving, wouldn't operate the mechanism, but only now and then. Assumed the electrics/switch mechanism were iffy. Took all the trim off but could find nothing that looked obviously bad. After much Googling I found a video from a bloke with a similar issue. The solution was to get the tailgate open somehow (my inside switch worked), then turn the engine on. This fixed my problem. Presume the computer got confused due to some weird order of door opening/locking/unlocking. Hope this saves someone a bit of pain.