diff options
author | Marc Coquand <marc@mccd.space> | 2024-05-16 08:51:04 -0500 |
---|---|---|
committer | Marc Coquand <marc@mccd.space> | 2024-05-16 08:51:04 -0500 |
commit | e57d29c39da80f9ef9cb68a9322ad2c4254f2d80 (patch) | |
tree | 5e606b670e2b3520fa102e24768c426216f87f46 /lib/headlines.ml | |
parent | 091cc7925e811c543bb3a55bc34dc439630fb063 (diff) | |
download | stitch-e57d29c39da80f9ef9cb68a9322ad2c4254f2d80.tar.gz stitch-e57d29c39da80f9ef9cb68a9322ad2c4254f2d80.tar.bz2 stitch-e57d29c39da80f9ef9cb68a9322ad2c4254f2d80.zip |
Fix regexp being empty error. Just display nothing for now
Diffstat (limited to 'lib/headlines.ml')
-rw-r--r-- | lib/headlines.ml | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/headlines.ml b/lib/headlines.ml index 31be26c..04b4267 100644 --- a/lib/headlines.ml +++ b/lib/headlines.ml @@ -41,7 +41,10 @@ let rec render let x, y = pos in let content_position = y - content_start in let img = - let dot = I.string A.(st bold) ">" |> I.pad ~l:0 ~t:(y - scroll) + let dot = + if Array.length content_pretty = 0 + then I.empty + else I.string A.(st bold) ">" |> I.pad ~l:0 ~t:(y - scroll) and elements = Array.mapi (fun i el -> |