Ruling allows release of John Hinckley Jr.