Browse Source

Stay compatible with Hitokoto API update

pull/6/head
Pisces000221 7 years ago committed by GitHub
parent
commit
c96233d221
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      views/index.ejs

2
views/index.ejs

@ -81,7 +81,7 @@
<div class="ui active centered inline loader" id="hitokoto-loader"></div> <div class="ui active centered inline loader" id="hitokoto-loader"></div>
<script> <script>
$.get('https://sslapi.hitokoto.cn/?c=a', function (data) { $.get('https://sslapi.hitokoto.cn/?c=a', function (data) {
data = JSON.parse(data); if (typeof data === 'string') data = JSON.parse(data);
$('#hitokoto-loader').removeClass('active'); $('#hitokoto-loader').removeClass('active');
$('#hitokoto-content').css('display', '').text(data.hitokoto); $('#hitokoto-content').css('display', '').text(data.hitokoto);
if (data.from) { if (data.from) {

Loading…
Cancel
Save