ZMediumToMarkdown 2.3.1 → 2.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ZMediumFetcher.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fd59f057d165b348b9a34b25c759c6b4d5d781c99fc9fd2533d75e34a458e111
|
4
|
+
data.tar.gz: 4affdd30a717a8bde0a8f0815072942c301a6a58bbc0ae09a32882ca84476bdf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ab8b9057e4bf01c40684451aad35019566a2e7bce663791c04fd4d696f80c5d474cb88caab489147704264db33babafd1511be88222c942fbdbdf558e91fb211
|
7
|
+
data.tar.gz: e694b475c6a2c3eab24cecb387c144a88910e6c324ef8967af9c6e4e79a78bc6ef84e05b9f8824d4a6bdff6514ff267283f0b9743ee6429097d8ae3cd6fff6cd
|
data/lib/ZMediumFetcher.rb
CHANGED
@@ -235,7 +235,7 @@ class ZMediumFetcher
|
|
235
235
|
absolutePath = URI.decode(postPathPolicy.getAbsolutePath("#{postWithDatePath}")) + ".md"
|
236
236
|
|
237
237
|
fileLatestPublishedAt = nil
|
238
|
-
filePinnedByCreatorAt =
|
238
|
+
filePinnedByCreatorAt = 0
|
239
239
|
if File.file?(absolutePath)
|
240
240
|
lines = File.foreach(absolutePath).first(15)
|
241
241
|
if lines.first&.start_with?("---")
|
@@ -245,7 +245,7 @@ class ZMediumFetcher
|
|
245
245
|
end
|
246
246
|
|
247
247
|
pinnedByCreatorAtLine = lines.select { |line| line.start_with?("pinned_at:") }.first
|
248
|
-
if !
|
248
|
+
if !pinnedByCreatorAtLine.nil?
|
249
249
|
filePinnedByCreatorAt = Time.parse(pinnedByCreatorAtLine[/^(pinned_at:)\s+(\S*)/, 2]).to_i
|
250
250
|
end
|
251
251
|
end
|