about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2018-05-27 feat(db): Update views with thread-closed fieldVincent Ambo3-0/+8
2018-05-27 feat(db): Add migration & fields to indicate a thread is closedVincent Ambo2-0/+2
2018-05-22 chore: Remove Tera usage in all modulesVincent Ambo3-28/+2
2018-05-22 refactor(templates): Move search result template to AskamaVincent Ambo1-2/+3
2018-05-22 refactor(templates): Move post editing template to AskamaVincent Ambo2-14/+14
2018-05-22 refactor(templates): Move thread page template to AskamaVincent Ambo2-6/+6
2018-05-22 refactor(templates): Use Askama for index templateVincent Ambo3-16/+40
2018-05-22 feat(templates): Add new MDL based index pageVincent Ambo1-1/+2
2018-05-19 refactor(handlers): Embed static files into binaryVincent Ambo2-13/+26
2018-05-19 feat(templates): Add syntax highlighting for code via highlight.jsVincent Ambo1-0/+11
Includes a static distribution of highlight.js for syntax highlighting. A sane set of languages has been chosen.
2018-05-02 refactor(handlers/render): Use users from database for all functionsVincent Ambo2-57/+54
Converse now sets the user ID as the session identity parameter in actix_web's identity middleware after a successful login and uses the ID to determine identity when creating threads & posts and when validating edit permissions.
2018-05-02 refactor(main): Use actix-web's identity middleware for authVincent Ambo1-5/+9
2018-05-02 feat(db): Add LookupOrCreateUser messageVincent Ambo2-0/+50
Adds a message to look up a user in the database based on their email address. If the user does not exist, it is created.
2018-05-02 refactor(db/render/schema): Use SimplePost type for thread viewsVincent Ambo4-30/+67
This uses the simplified view for querying posts instead of the post table directly to display posts.
2018-05-02 fix(schema): Update for author->user_id column renameVincent Ambo1-4/+4
2018-05-02 chore(schema): Update generated Diesel schemaVincent Ambo1-4/+14
Updates the generated schema with the new users table. This commit will break the build.
2018-04-17 chore(license): Relicense under AGPL-3.0-or-laterVincent Ambo8-56/+88
Relicense the project from the standard GPL3 to the Affero version of the license, requiring source code disclosure for modifications made on instances of Converse that are serving users over the network.
2018-04-16 feat(templates): Add 'Last post by' to the list of threadsTatriX1-0/+2
2018-04-16 style(db): Fix whitespace errorVincent Ambo1-1/+1
2018-04-16 fix(db): Explicitly order posts in a threadVincent Ambo1-2/+5
2018-04-16 fix(render): Enable GFM's tagfilter extensionVincent Ambo2-2/+2
2018-04-16 chore(oidc): Enable debug log statement for token responsesVincent Ambo1-4/+6
2018-04-16 refactor(main): Include Tera templates into application binaryVincent Ambo1-7/+15
Instead of loading the templates at launch time (which requires the template folder to be present), include the template strings into the binary. This also re-enables auto-escaping in Tera.
2018-04-15 feat(handlers): Implement post editing handlerVincent Ambo3-2/+31
Implements a handler that receives the edit form result and updates the database accordingly if the user identity matches.
2018-04-15 feat(db): Support UpdatePost messageVincent Ambo1-0/+23
Simple message intended to be used for post editing.
2018-04-15 feat(handlers/render): Display edit form for user's own postsVincent Ambo4-1/+62
Displays an edit form for posts that are owned by a user (which is currently defined as "email addresses match").
2018-04-15 feat(db): Support GetPost messageVincent Ambo1-0/+16
Very simple message that retrieves a post from the DB.
2018-04-15 refactor: Add a message!-macro to reduce message boilerplateVincent Ambo4-48/+22
2018-04-15 refactor(render): Pass serializable structs to Tera directlyVincent Ambo1-9/+3
No need to go the intermediate step via `Context::new()`
2018-04-15 refactor(templates/render): Add generic post editing templateVincent Ambo3-15/+52
Adds a generic template that can be used for submitting, responding to and editing posts.
2018-04-15 refactor(main): Split enormous main() into smaller methodsVincent Ambo1-38/+58
A little bit of logical grouping of things has never hurt anyone.
2018-04-15 fix(handlers): Trim leading/trailing whitespace from new threadsVincent Ambo1-6/+12
2018-04-15 feat(handlers): Determine whether current user can edit a postVincent Ambo3-3/+19
2018-04-14 refactor(handlers): Receive search terms via query parametersVincent Ambo2-4/+4
There are several reasons for this, but one important one is that people expect to be able to share search links.
2018-04-14 fix(render): Escape post bodiesVincent Ambo1-1/+2
... derp. Well, the CSP prevented script executions already.
2018-04-14 feat: Implement search result view & enable searchVincent Ambo4-1/+39
Implements a very simple and currently kinda broken-looking search result view.
2018-04-14 chore(db): Arbitrarily limit search result sizeVincent Ambo1-0/+1
... until pagination is in place.
2018-04-14 feat(main/db): Schedule regular search view refreshVincent Ambo3-0/+50
Schedules refreshes of the database view used for search at one-minute intervals.
2018-04-14 refactor(schema): Unify integer type usage across tablesVincent Ambo1-2/+2
2018-04-14 refactor(handlers): Improve error handling in post creationVincent Ambo1-2/+2
2018-04-14 feat(db): Implement handling of 'SearchPosts' messageVincent Ambo2-1/+61
Adds support for executing full-text search across a forum instance by sending the `SearchPosts` message with a search query to the DB actor. The struct used for results is mapped manually to the expected query result as the query is embedded via raw SQL.
2018-04-14 feat(templates): Highlight stickied threads in indexVincent Ambo1-0/+2
2018-04-14 feat(db): Add support for stickies in databaseVincent Ambo3-5/+13
Adds a 'sticky' column to threads and rewrites the thread index to take sticky markings into account when ordering threads. Stickies are not yet highlighted in any way in the forum overview.
2018-04-14 feat(db): Add view for ordering thread index by most recent postVincent Ambo4-7/+29
This implements the classic thread ordering expected by most forum users (i.e. the thread with the most recent post is at the top).
2018-04-14 feat: License project under GPLv3Vincent Ambo7-0/+112
2018-04-14 refactor(db): Store thread body in the posts tableVincent Ambo5-23/+36
This is a simplification over the previous approach. The OP of a thread is just a normal post like any other in this model, which allows some code simplifications (and future query convenience).
2018-04-12 feat(handlers/main): Add 'anonymous' mode for forumVincent Ambo2-9/+27
Adds a `REQUIRE_LOGIN` environment variable which, if set to anything other than true, will let users post anonymously on the forums.
2018-04-12 feat(handler): Perform basic input validation on new thread viewVincent Ambo2-5/+32
2018-04-12 fix(handlers): Fix chained error handling in actorsVincent Ambo1-14/+15
This took me some time to figure out so it's useful to document in the commit message. When chaining messages from actors, the result type of a message (i.e. the actual `<M as Message>::Result`) is sometimes itself a `Result<T, E>`. In many cases this leads to a situation where the return type of a message sending process is something like (simplified): Future<Item=Result<Foo, ConverseError>, Error=actix::MailboxError> Due to the implementation of `From<actix::MailboxError> for ConverseError` it is possible to use `.from_err()` on these futures to convert the future's `Error` to `ConverseError`. The type `Result` apparently implements `IntoFuture`, which means that due to some trait magic that's been applied somewhere in the futures API a call to `flatten()` can "lift" the contained error if the error types match and give us a "simple" Future<Item=Foo, Error=ConverseError> From that point on chaining becomes easy.
2018-04-11 chore(handlers): Remove unused codeVincent Ambo1-8/+0