Skip to content
Myr

Removed unused stuff from minitwit and fixed a bug.

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Armin Ronacher · committed by Armin Ronacher · parent 0770f5c · Browse files · 1 file+1 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−3 removed

  • other:+1 added−3 removed

1 file+1 added−3 removed

modified:examples/minitwit/minitwit.py+1 added-3 removed
7 unmodified lines
8 :copyright: (c) 2010 by Armin Ronacher.9 :license: BSD, see LICENSE for more details.10"""11from __future__ import with_statement12import re12import time13import sqlite314from hashlib import md515from datetime import datetime
78 unmodified lines
94 messages as well as all the messages of followed users.95 """96 if not g.user:97 return redirect(url_for('public_timeline'))99 offset = request.args.get('offset', type=int)98 return render_template('timeline.html', messages=query_db('''99 select message.*, user.* from message, user100 where message.author_id = user.user_id and (101 user.user_id = ? or
18 unmodified lines
120 profile_user = query_db('select * from user where username = ?',121 [username], one=True)122 if profile_user is None:123 abort(404)126 followd = False124 followed = False125 if g.user:126 followed = query_db('''select 1 from follower where127 follower.who_id = ? and follower.whom_id = ?''',128 [session['user_id'], profile_user['user_id']], one=True) is not None
120 unmodified lines