Commit 16038590 authored by Eugen Rochko's avatar Eugen Rochko

Display count of users on frontpage

parent 9dc66aca
class HomeController < ApplicationController class HomeController < ApplicationController
def index def index
@twitter_count = Authorization.where(provider: :twitter).count
@mastodon_count = Authorization.where(provider: :mastodon).count
end end
end end
...@@ -29,7 +29,11 @@ ...@@ -29,7 +29,11 @@
</tbody> </tbody>
</table> </table>
<p><%= link_to "Find friends on Mastodon", friends_path %></p> <ul>
<li><%= link_to "Find friends on Mastodon", friends_path %></li>
<% else %> <% else %>
<p>You are not signed in</p> <p>You are not signed in</p>
<% end %> <% end %>
<p>So far, <strong><%= @twitter_count %></strong> users signed in with Twitter, and <strong><%= @mastodon_count %></strong> with Mastodon. Are your friends or followers among them?</p>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment