* Check if a conversation has already been created in the database. If the conversation is not found, a new conversation is created. start fetch the data stored in the database
* Check if a conversation has already been created in the database. If the conversation is not found, a new conversation is created. Start fetches the data stored in the database.
*
* @return bool
*/
...
...
@@ -148,11 +146,13 @@ class Conversation
/**
* Store the array/variable in the database with json_encode() function
*
* @todo Verify the query before assigning the $data member variable
*
* @param array $data
*/
publicfunctionupdate($data)
{
//conversation must exist!
//Conversation must exist!
if($this->conversationExist()){
$fields['data']=json_encode($data);
...
...
@@ -165,11 +165,9 @@ class Conversation
/**
* Delete the conversation from the database
*
* Currently the Convevrsation is not deleted but just unsetted
* Currently the Conversation is not deleted but just set to 'stopped'
*
* @TODO should return something
*
* @param array $data
* @todo should return something
*/
publicfunctionstop()
{
...
...
@@ -181,7 +179,7 @@ class Conversation
/**
* Retrieve the command to execute from the conversation