Skip to content
This repository has been archived by the owner on Mar 9, 2022. It is now read-only.

Commit

Permalink
Fix unnecessary 401 challenges
Browse files Browse the repository at this point in the history
MYURLUtils' method -my_credentialForRealm: is returning a credential with no persistence
when the URL has a baked-in username and password. This turns out to prevent NSURLConnection
from proactively sending the same credential on the next connection to the host, with the bad
effect that every connection initially gets a 401 and only then gets the credential and retries. This
slows down performance.
Fixed this by changing the persistence to NSURLCredentialPersistenceForSession.
I believe this fixes #197 in TouchDB.
  • Loading branch information
snej committed Dec 13, 2012
1 parent 7687f07 commit c61530c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vendor/MYUtilities
Submodule MYUtilities updated from d9335d to 7ae6d1

0 comments on commit c61530c

Please sign in to comment.