diff options
| author | eltrac <hi@eltr.ac> | 2026-09-24 11:49:02 +0800 |
|---|---|---|
| committer | eltrac <hi@eltr.ac> | 2026-09-24 11:49:50 +0800 |
| commit | 5fa1f0cb40153410964c2431c3e1bd16ce309b0e (patch) | |
| tree | fcbe774b7d9d85e974c6ccfeed69f634e6c6bd59 /src | |
| parent | 8e10c8c1a6b522f43bdae539900bfe6cd6ef86b8 (diff) | |
microformats.reducer: fallback to same-level h-card if h-entry lacks author property
Diffstat (limited to 'src')
| -rw-r--r-- | src/weepinbell/microformats/reducer.clj | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/weepinbell/microformats/reducer.clj b/src/weepinbell/microformats/reducer.clj index e93fc8c..0407b74 100644 --- a/src/weepinbell/microformats/reducer.clj +++ b/src/weepinbell/microformats/reducer.clj @@ -21,7 +21,8 @@ (let [items (use-items mf)
entry (find-h-entry items)
card (find-h-card items)
- author (->> entry (use-prop :author))
+ author (or (->> entry (use-prop :author))
+ card)
photo (or (search-photo author)
(search-photo card))
data {:author {:name (use-prop :name author)
|
