summaryrefslogtreecommitdiff
path: root/src/gempub.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gempub.c')
-rw-r--r--src/gempub.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gempub.c b/src/gempub.c
index 0f0345dc..aa03d835 100644
--- a/src/gempub.c
+++ b/src/gempub.c
@@ -206,13 +206,17 @@ void close_Gempub(iGempub *d) {
206} 206}
207 207
208void setBaseUrl_Gempub(iGempub *d, const iString *url) { 208void setBaseUrl_Gempub(iGempub *d, const iString *url) {
209 set_String(&d->baseUrl, url); 209 set_String(&d->baseUrl, collect_String(urlDecodeExclude_String(url, "/:")));
210} 210}
211 211
212iBool isOpen_Gempub(const iGempub *d) { 212iBool isOpen_Gempub(const iGempub *d) {
213 return d->arch != NULL; 213 return d->arch != NULL;
214} 214}
215 215
216const iString *coverPageUrl_Gempub(const iGempub *d) {
217 return &d->baseUrl;
218}
219
216const iString *indexPageUrl_Gempub(const iGempub *d) { 220const iString *indexPageUrl_Gempub(const iGempub *d) {
217 iAssert(!isEmpty_String(&d->baseUrl)); 221 iAssert(!isEmpty_String(&d->baseUrl));
218 iString *dir = collect_String(copy_String(&d->baseUrl)); 222 iString *dir = collect_String(copy_String(&d->baseUrl));