Skip to content

Commit e14debd

Browse files
authored
Merge pull request #246 from weiran/hnfix
Adapt to changed HTML
2 parents 41f6e15 + cbfda1a commit e14debd

File tree

5 files changed

+13
-10
lines changed

5 files changed

+13
-10
lines changed

App/Services/OnboardingService.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ enum OnboardingService {
1515
return nil
1616
}
1717

18+
// disable onboarding
19+
return nil
20+
1821
let whatsNew = WhatsNew(
1922
title: "What's New in Hackers",
2023
items: items()

Extensions/HackersActionExtension/Info.plist

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@
1717
<key>CFBundlePackageType</key>
1818
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
1919
<key>CFBundleShortVersionString</key>
20-
<string>4.7.5</string>
20+
<string>4.7.6</string>
2121
<key>CFBundleVersion</key>
22-
<string>115</string>
22+
<string>116</string>
2323
<key>NSExtension</key>
2424
<dict>
2525
<key>NSExtensionAttributes</key>

Extensions/HackersShareExtension/Info.plist

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@
1717
<key>CFBundlePackageType</key>
1818
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
1919
<key>CFBundleShortVersionString</key>
20-
<string>4.7.5</string>
20+
<string>4.7.6</string>
2121
<key>CFBundleVersion</key>
22-
<string>115</string>
22+
<string>116</string>
2323
<key>NSExtension</key>
2424
<dict>
2525
<key>NSExtensionAttributes</key>

Hackers.xcodeproj/project.pbxproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1270,7 +1270,7 @@
12701270
CODE_SIGN_ENTITLEMENTS = "App/Supporting Files/Hackers.entitlements";
12711271
CODE_SIGN_IDENTITY = "iPhone Developer";
12721272
CODE_SIGN_STYLE = Manual;
1273-
CURRENT_PROJECT_VERSION = 115;
1273+
CURRENT_PROJECT_VERSION = 116;
12741274
DEVELOPMENT_TEAM = 2KB59GPA9B;
12751275
FRAMEWORK_SEARCH_PATHS = "$(inherited)";
12761276
GCC_PRECOMPILE_PREFIX_HEADER = YES;
@@ -1281,7 +1281,7 @@
12811281
"$(inherited)",
12821282
"@executable_path/Frameworks",
12831283
);
1284-
MARKETING_VERSION = 4.7.5;
1284+
MARKETING_VERSION = 4.7.6;
12851285
PRODUCT_BUNDLE_IDENTIFIER = "com.weiranzhang.$(PRODUCT_NAME:rfc1034identifier)";
12861286
PRODUCT_NAME = Hackers;
12871287
PROVISIONING_PROFILE_SPECIFIER = "Hackers Dev Profile";
@@ -1302,7 +1302,7 @@
13021302
CODE_SIGN_ENTITLEMENTS = "App/Supporting Files/Hackers.entitlements";
13031303
CODE_SIGN_IDENTITY = "iPhone Distribution";
13041304
CODE_SIGN_STYLE = Manual;
1305-
CURRENT_PROJECT_VERSION = 115;
1305+
CURRENT_PROJECT_VERSION = 116;
13061306
DEVELOPMENT_TEAM = 2KB59GPA9B;
13071307
FRAMEWORK_SEARCH_PATHS = "$(inherited)";
13081308
GCC_PRECOMPILE_PREFIX_HEADER = YES;
@@ -1313,7 +1313,7 @@
13131313
"$(inherited)",
13141314
"@executable_path/Frameworks",
13151315
);
1316-
MARKETING_VERSION = 4.7.5;
1316+
MARKETING_VERSION = 4.7.6;
13171317
PRODUCT_BUNDLE_IDENTIFIER = "com.weiranzhang.$(PRODUCT_NAME:rfc1034identifier)";
13181318
PRODUCT_NAME = Hackers;
13191319
PROVISIONING_PROFILE_SPECIFIER = "Hackers Prod Profile";

Shared Frameworks/HackersKit/HtmlParser.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ enum HtmlParser {
4242
guard let id = Int(try postElement.attr("id")) else {
4343
throw Exception.Error(type: .SelectorParseException, Message: "Couldn't parse post ID")
4444
}
45-
let urlString = try postElement.select(".titlelink").attr("href")
46-
let title = try postElement.select(".titlelink").text()
45+
let urlString = try postElement.select(".titleline").select("a").attr("href")
46+
let title = try postElement.select(".titleline").text()
4747
guard let url = URL(string: urlString) else {
4848
throw Exception.Error(type: .SelectorParseException, Message: "Couldn't parse post URL")
4949
}

0 commit comments

Comments
 (0)