Skip to content

Commit

Permalink
去除搜图功能
Browse files Browse the repository at this point in the history
  • Loading branch information
chenxuuu committed May 24, 2019
1 parent aea7a63 commit 13f8729
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 33 deletions.
39 changes: 39 additions & 0 deletions appdata/lua/require/app/hitokoto.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
--一言
return function ()
local say = apiHttpGet("http://v1.hitokoto.cn")

local types = {
a = "Anime - 动画",
b = "Comic – 漫画",
c = "Game – 游戏",
d = "Novel – 小说",
e = "Myself – 原创",
f = "Internet – 来自网络",
g = "Other – 其他",
}

function getText(s)
if not s then return end

local data = JSON:decode(s)
if not s then return end

local hitokoto,saytype,from
if not pcall(function ()
hitokoto,saytype,from = data.hitokoto, data.type, data.from
end) then
return
end

return hitokoto.."\r\n--"..from.."\r\n"..types[saytype]
end

return getText(say) or at(fromqq).."\r\n加载失败啦"

end






33 changes: 0 additions & 33 deletions appdata/lua/require/app/imageSearch.lua

This file was deleted.

0 comments on commit 13f8729

Please sign in to comment.