fix#13 (#19)
* fix for #13 * requirements.txt entry * rm striptags + bleach configuration
This commit is contained in:
@@ -15,6 +15,7 @@ ALLOWED_HOSTS = ["127.0.0.1", "0.0.0.0", "vas3k.ru", "infomate.club"]
|
||||
INSTALLED_APPS = [
|
||||
"django.contrib.staticfiles",
|
||||
"django.contrib.humanize",
|
||||
"django_bleach",
|
||||
"auth",
|
||||
"boards",
|
||||
"parsing"
|
||||
@@ -122,6 +123,8 @@ TELEGRAM_APP_HASH = None # should set in private_settings.py
|
||||
TELEGRAM_SESSION_FILE = None # should set in private settings.py
|
||||
TELEGRAM_CACHE_SECONDS = 10 * 60 # 10 min
|
||||
|
||||
BLEACH_STRIP_TAGS = True
|
||||
|
||||
try:
|
||||
# poor mans' private settings
|
||||
# As due to obvious reasons this file is missing in the repository, suppress the following 'pyflakes' error codes:
|
||||
|
||||
@@ -12,3 +12,4 @@ pyjwt>=1.7.1
|
||||
nltk==3.4.5
|
||||
newspaper3k>=0.2.8
|
||||
telethon==1.10.10
|
||||
django-bleach==0.6.1
|
||||
@@ -1,6 +1,7 @@
|
||||
{% extends "layout.html" %}
|
||||
{% load text_filters %}
|
||||
{% load static %}
|
||||
{% load bleach_tags %}
|
||||
|
||||
{% block title %}{{ board.curator_name }}{% if board.curator_title %} | {{ board.curator_title }}{% endif %} | {{ block.super }}{% endblock %}
|
||||
|
||||
@@ -68,7 +69,7 @@
|
||||
<div class="articles feed-articles">
|
||||
{% for article in articles %}
|
||||
<div class="article {% if article.is_fresh %}is-article-fresh{% endif %}">
|
||||
<div class="article-title">{{ article.icon|safe }}<a href="{{ article.url }}" target="_blank">{{ article.title|striptags }}</a></div>
|
||||
<div class="article-title">{{ article.icon|safe }}<a href="{{ article.url }}" target="_blank">{{ article.title|bleach }}</a></div>
|
||||
<a href="{{ article.url }}" class="article-tooltip" target="_blank">
|
||||
{% if article.image %}
|
||||
<img src="{{ article.image }}" alt="{{ article.title|striptags }}" class="article-tooltip-image">
|
||||
|
||||
Reference in New Issue
Block a user