Compare commits
No commits in common. "main" and "main" have entirely different histories.
|
@ -3,4 +3,3 @@ cache/
|
|||
tests/
|
||||
minelife.html
|
||||
vendors/keygen/__pycache__
|
||||
erreurs/
|
|
@ -44,13 +44,6 @@ class GchangeUser {
|
|||
}
|
||||
}
|
||||
|
||||
static public function constructVoidUser ($pubkey) {
|
||||
|
||||
$this->userGchangeId = $pubkey;
|
||||
|
||||
$this->userName = substr($this->userGchangeId, 0, 8);
|
||||
}
|
||||
|
||||
public function getUserGchangeId () {
|
||||
|
||||
return $this->userGchangeId;
|
||||
|
|
|
@ -62,7 +62,7 @@ class Jaklis {
|
|||
$cmd .= ' read';
|
||||
$cmd .= ' --number ' . $this->msgLimit;
|
||||
$cmd .= ' --json';
|
||||
|
||||
|
||||
$output=null;
|
||||
$result_code=null;
|
||||
exec($cmd, $output, $result_code);
|
||||
|
|
|
@ -81,16 +81,7 @@ class Messenger {
|
|||
|
||||
if (!isset($users[$penpalPubkey])) {
|
||||
|
||||
try {
|
||||
|
||||
$user = $this->gchange->getUser($penpalPubkey);
|
||||
|
||||
$this->users[$penpalPubkey] = $user;
|
||||
|
||||
} catch (Exception $e) {
|
||||
|
||||
$this->users[$penpalPubkey] = GchangeUser::constructVoidUser($penpalPubkey);
|
||||
}
|
||||
$this->users[$penpalPubkey] = $this->gchange->getUser($penpalPubkey);
|
||||
}
|
||||
}
|
||||
public function getConversation ($penpalGchangeId) {
|
||||
|
|
|
@ -42,14 +42,7 @@ try {
|
|||
// echo '<pre>'; var_dump($msgOut); echo '</pre>';
|
||||
// die();
|
||||
|
||||
try {
|
||||
|
||||
$messenger->addMessages($msgIn, $msgOut);
|
||||
|
||||
} catch (Exception $e) {
|
||||
|
||||
// L'utilisateur {...} n'a été trouvé nulle part.
|
||||
}
|
||||
$messenger->addMessages($msgIn, $msgOut);
|
||||
|
||||
// echo '<pre>'; var_dump($messenger->getConversations()); echo '</pre>';
|
||||
|
||||
|
|
Loading…
Reference in New Issue