From: Jay Freeman (saurik) Date: Fri, 11 Mar 2011 01:06:06 +0000 (-0800) Subject: Fix SourceController state saving. X-Git-Tag: v1.1.0%b5~3 X-Git-Url: https://git.saurik.com/cydia.git/commitdiff_plain/6cfdc30696e4c462f898e9dfa4a202f957dca5d7 Fix SourceController state saving. --- diff --git a/MobileCydia.mm b/MobileCydia.mm index 758e6622..c3ac471f 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -8058,7 +8058,7 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { @implementation SourceController - (NSURL *) navigationURL { - return [NSURL URLWithString:[NSString stringWithFormat:@"cydia://sources/%@", [source_ name]]]; + return [NSURL URLWithString:[NSString stringWithFormat:@"cydia://sources/%@", [key_ stringByAddingPercentEscapesIncludingReserved]]]; } - (id) initWithDatabase:(Database *)database source:(Source *)source { @@ -9485,7 +9485,7 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { controller = [[[SourcesController alloc] initWithDatabase:database_] autorelease]; [(SourcesController *)controller showAddSourcePrompt]; } else { - Source *source = [database_ sourceWithKey:argument]; + Source *source = [database_ sourceWithKey:[argument stringByReplacingPercentEscapesUsingEncoding:NSUTF8StringEncoding]]; controller = [[[SourceController alloc] initWithDatabase:database_ source:source] autorelease]; } }