Fossil SCM
For the wiki_render_page_list_json() function, only include pages on the list if they have one or more artifacts. This seems to clears the bug described by ["Wiki editor inop" forum post](forum:a9e345482e).
Commit
5244a5484a103065aa15cbeadeb93990398f0ead392e0bcec4d307a72d0a1316
Parent
f4dc114a780fea4…
1 file changed
+2
-1
+2
-1
| --- src/wiki.c | ||
| +++ src/wiki.c | ||
| @@ -1004,11 +1004,12 @@ | ||
| 1004 | 1004 | Stmt q = empty_Stmt; |
| 1005 | 1005 | int n = 0; |
| 1006 | 1006 | db_begin_transaction(); |
| 1007 | 1007 | db_prepare(&q, "SELECT" |
| 1008 | 1008 | " substr(tagname,6) AS name" |
| 1009 | - " FROM tag WHERE tagname GLOB 'wiki-*'" | |
| 1009 | + " FROM tag JOIN tagxref USING('tagid')" | |
| 1010 | + " WHERE tagname GLOB 'wiki-*'" | |
| 1010 | 1011 | " UNION SELECT 'Sandbox' AS name" |
| 1011 | 1012 | " ORDER BY name COLLATE NOCASE"); |
| 1012 | 1013 | CX("["); |
| 1013 | 1014 | while( SQLITE_ROW==db_step(&q) ){ |
| 1014 | 1015 | char const * zName = db_column_text(&q,0); |
| 1015 | 1016 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -1004,11 +1004,12 @@ | |
| 1004 | Stmt q = empty_Stmt; |
| 1005 | int n = 0; |
| 1006 | db_begin_transaction(); |
| 1007 | db_prepare(&q, "SELECT" |
| 1008 | " substr(tagname,6) AS name" |
| 1009 | " FROM tag WHERE tagname GLOB 'wiki-*'" |
| 1010 | " UNION SELECT 'Sandbox' AS name" |
| 1011 | " ORDER BY name COLLATE NOCASE"); |
| 1012 | CX("["); |
| 1013 | while( SQLITE_ROW==db_step(&q) ){ |
| 1014 | char const * zName = db_column_text(&q,0); |
| 1015 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -1004,11 +1004,12 @@ | |
| 1004 | Stmt q = empty_Stmt; |
| 1005 | int n = 0; |
| 1006 | db_begin_transaction(); |
| 1007 | db_prepare(&q, "SELECT" |
| 1008 | " substr(tagname,6) AS name" |
| 1009 | " FROM tag JOIN tagxref USING('tagid')" |
| 1010 | " WHERE tagname GLOB 'wiki-*'" |
| 1011 | " UNION SELECT 'Sandbox' AS name" |
| 1012 | " ORDER BY name COLLATE NOCASE"); |
| 1013 | CX("["); |
| 1014 | while( SQLITE_ROW==db_step(&q) ){ |
| 1015 | char const * zName = db_column_text(&q,0); |
| 1016 |