Commit 8773b59f by Googler Committed by microkatz

Clarify exception message.

The exception fires when intent resolution fails to find a service which declares an appropriate intent-filter. The existing message is confusing; it's trying to say that the service couldn't be found but the double negative renders it incorrect.

#cleanup
#minor-release

PiperOrigin-RevId: 472736740
(cherry picked from commit 15d3d74e)
parent e6a725b6
......@@ -118,10 +118,10 @@ public final class SessionToken implements Bundleable {
type = TYPE_BROWSER_SERVICE_LEGACY;
} else {
throw new IllegalArgumentException(
serviceComponent
+ " doesn't implement none of"
+ " MediaSessionService, MediaLibraryService, MediaBrowserService nor"
+ " MediaBrowserServiceCompat. Use service's full name");
"Failed to resolve SessionToken for "
+ serviceComponent
+ ". Manifest doesn't declare one of either MediaSessionService, MediaLibraryService,"
+ " MediaBrowserService or MediaBrowserServiceCompat. Use service's full name.");
}
if (type != TYPE_BROWSER_SERVICE_LEGACY) {
impl = new SessionTokenImplBase(serviceComponent, uid, type);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment