Commit Graph

10 Commits

Author SHA1 Message Date
deadvey
9f0eb13bb4 BAD BUG! 2025-10-24 13:10:53 +01:00
deadvey
2d33ce79a8 Fixed a bug where comments could be submitted without any content
and where the hitcount was incremented before the program checked if
the post existed
2025-10-24 13:05:31 +01:00
2ada1d970f Created a per-post hitcount as well a writedata() function that can
write to a particular index or to a whole data type
2025-10-02 13:34:55 +01:00
996bf0018b bug fix
numbers should be parsed

Signed-off-by: deadvey <deadvey@deadvey.com>
2025-09-24 21:21:48 +01:00
45af80f747 Updated how comments are searched for
commentID's aren't neccesarily = to the index, so instead of using it as an index,  I just use a for loop to find the matching comment.
I also added another form at the bottom of the timeline to trick bots

Signed-off-by: deadvey <deadvey@deadvey.com>
2025-09-24 21:12:21 +01:00
23744f4000 Bug fix and Document fix
Removed the string object from config.json as it's now all in the locale.
and I fixed data.getdata() to return an error code if the index is out of bounds, it now returns a 1.

Signed-off-by: deadvey <deadvey@deadvey.com>
2025-09-24 20:57:47 +01:00
22a7983737 data.getdata() is fully implemented
I think it all works now...

Signed-off-by: deadvey <deadvey@deadvey.com>
2025-09-24 19:31:32 +01:00
e597fd78f7 Comment replies on comment page
There is now a reply form on the comment pages to reply to that comment
Syntax:
>> postID-commentID

Signed-off-by: deadvey <deadvey@deadvey.com>
2025-09-24 17:33:25 +01:00
max
e6476dcd4e Everything uses data.getdata()
data.getdata() excepts two parameters, if desired, the second will be the index, however if you don't specify anything, the whole array will be returned
Also, comments now have a composite key of postID-commentID, with each post's comments having their own set starting at 0, this makes it easier to index and find a specific comment, and making the getcomment() function unessesary
2025-09-24 17:06:13 +01:00
max
93c5f13750 Clean up changes
Seperated all routes into seperate files for neatness, and I've made the comments.json store only the comments, comments_counter is in the new data.json file which also stores the hitcount.

Signed-off-by: max <deadvey@localhost.localdomain>
2025-09-24 10:02:28 +01:00