Skip to content
This repository has been archived by the owner on Mar 5, 2022. It is now read-only.

Commit

Permalink
Update update.inc.php
Browse files Browse the repository at this point in the history
  • Loading branch information
mrjun12 authored Mar 11, 2020
1 parent 9d932e8 commit a176c08
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions update.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,12 @@

mkdir ('./smms_imglist/',0777,true);
copy($lastname,$path);
unlink($lastname);


$auth = $_G["cache"]["plugin"]["smms_image"]["secret"];
$smapi = new SMApi($auth);
$result = $smapi->Upload($path);
unlink($path);

if($result["code"] == "image_repeated"){
$result['data']['url'] = $result["images"];
Expand All @@ -21,4 +22,4 @@
header('Content-Type:application/json; charset=utf-8');
echo json_encode($result);

?>
?>

0 comments on commit a176c08

Please sign in to comment.