This repository was archived by the owner on Apr 7, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +13
-9
lines changed Expand file tree Collapse file tree 2 files changed +13
-9
lines changed Original file line number Diff line number Diff line change 2
2
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
3
<plist version =" 1.0" >
4
4
<dict >
5
+ <key >LSApplicationQueriesSchemes </key >
6
+ <array >
7
+ <string >studyplus </string >
8
+ </array >
5
9
<key >CFBundleDevelopmentRegion </key >
6
10
<string >en </string >
7
11
<key >CFBundleExecutable </key >
Original file line number Diff line number Diff line change @@ -299,20 +299,20 @@ final public class Studyplus {
299
299
300
300
private func openStudyplus( command: String ) {
301
301
302
- let urlString : String = " studyplus://external_app/ " + command + " / " + consumerKey + " / " + consumerSecret
303
-
304
- if let url = URL ( string: urlString) {
305
-
306
- applicationOpen ( url)
307
-
308
- } else {
309
-
302
+ guard UIApplication . shared. canOpenURL ( URL ( string: " studyplus:// " ) !) else {
310
303
if self . openAppStoreIfNotInstalled {
311
-
312
304
let appStoreURLString : String = " https://apps.apple.com/jp/app/id505410049?mt=8 "
313
305
guard let appStoreURL = URL ( string: appStoreURLString) else { return }
314
306
applicationOpen ( appStoreURL)
315
307
}
308
+ return
309
+ }
310
+
311
+ let urlString : String = " studyplus://external_app/ " + command + " / " + consumerKey + " / " + consumerSecret
312
+
313
+ if let url = URL ( string: urlString) {
314
+
315
+ applicationOpen ( url)
316
316
}
317
317
}
318
318
You can’t perform that action at this time.
0 commit comments