Turn off RVT Links in Revit 2018 - Doesn't update the Visibility Graphics Setting

This code works for turning off the RVT Links Category in Revit, however the checkbox in Visibility Graphics isn’t getting updated. Probably because it isn’t turning off the specific link visibility in the view. Any thoughts:

categories = doc.Settings.Categories
for c in categories: 
    #print c.Name
    if c.Name == "RVT Links":
        #print c.Name
        selectedcat = c

for v in selectedviews:
    catId = selectedcat.Id
    try:
        v.SetCategoryHidden(catId, not bool) #Revit 2017, 2018 specific method
        print v.Title + " - " + selectedcat.Name + " Success"
    except:
        print v.Title + " - " + selectedcat.Name + " Failed"
        pass