dissenting:
In concluding that Brooks does not have a cause of action under section 1983, the majority apparently agrees that the County had a duty to respect Brooks’s right to be taken before a federal magistrate “without unnecessary delay.”1 However, the majority holds that even if the County had an official policy of intentional neglect toward federal detainees, it could not have been the legal cause of Brooks’s injury. This is so, the majority says, because the County could not have taken Brooks before a federal magistrate itself. Only federal officials could have taken Brooks before a federal magistrate, and therefore only federal officials were the cause of his injury.
The majority’s view of causation seems overly rigid. Although the County could not have taken Brooks before a federal magistrate, it was not helpless to avoid his injury. The County could have tracked Brooks’s status and, after several days had passed, reminded federal officials of his right to see a magistrate. It is true the County could not have guaranteed that federal officials would heed this reminder. But in a similar case, Oviatt v. Pearce, 954 F.2d 1470, 1478 (9th Cir.1992), we upheld a prisoner’s successful section 1983 action where it was only “unlikely” that the injury would have occurred under a proper tracking system. Here, it is unlikely that federal officials would have ignored a reminder from the County. Therefore, the County was not helpless to avoid the injury to Brooks and so was a legal cause of his injury.
The County also could have avoided the injury to Brooks in another way: by releasing him. The majority contends that the County was precluded from this step by CaLPenal Code § 4005(a), which required the County to hold Brooks until federal authorities said otherwise. That requirement, however, could not trump Brooks’s federal right not to be locked in jail without being brought before a magistrate.
Because I believe the County was a legal cause of Brooks’s injury, I respectfully *1251dissent.2
. As the majority points out, this right derives from several sources: 18 U.S.C. § 3142(f); Federal Rule of Criminal Procedure 5(a); and Northern District of California Local Criminal Rule 5-1 (c). California Penal Code § 825 also provides that a "defendant shall in all cases be taken before the magistrate without unnecessary delay, and, in any event, within 48 hours after his or her arrest, excluding Sundays and holidays.” The delay in this case was 12 days, although under the majority's view, it would make no difference if the delay was 100 days.
. I also would conclude that the district court abused its discretion in denying Brooks leave to amend his complaint a second time. The record in this case contains no evidence of undue delay, bad faith, dilatory motive, repeated failure to cure deficiencies, or undue prejudice to the opposing party. See Moore v. Kayport Package Express, Inc., 885 F.2d 531, 538 (9th Cir. 1989).