1
0
Fork 0
mirror of https://github.com/KingDuckZ/kamokan.git synced 2025-08-07 12:59:45 +00:00

Redirect to the new page if pastie was successful.

This commit is contained in:
King_DuckZ 2017-04-07 00:31:06 +01:00
parent 4354f4bf29
commit ef9e74c473
6 changed files with 71 additions and 20 deletions

View file

@ -19,6 +19,7 @@
#include "response.hpp"
#include <string>
#include <boost/optional.hpp>
namespace redis {
class IncRedis;
@ -30,9 +31,11 @@ namespace tawashi {
explicit SubmitPasteResponse (redis::IncRedis& parRedis);
private:
virtual void on_process() override;
virtual void on_send (std::ostream& parStream) override;
bool submit_to_redis (const std::string& parText) const;
boost::optional<std::string> submit_to_redis (const std::string& parText) const;
redis::IncRedis& m_redis;
std::string m_error_message;
};
} //namespace tawashi