Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gajim
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Weblate
gajim
Commits
19306fbf
Commit
19306fbf
authored
13 years ago
by
Yann Leboulanger
Browse files
Options
Downloads
Patches
Plain Diff
remove old unused function
parent
d58241df
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/common/connection_handlers.py
+0
-49
0 additions, 49 deletions
src/common/connection_handlers.py
with
0 additions
and
49 deletions
src/common/connection_handlers.py
+
0
−
49
View file @
19306fbf
...
@@ -1673,55 +1673,6 @@ ConnectionJingle, ConnectionIBBytestream):
...
@@ -1673,55 +1673,6 @@ ConnectionJingle, ConnectionIBBytestream):
self
.
connection
.
SendAndCallForResponse
(
iq
,
self
.
_on_bob_received
,
self
.
connection
.
SendAndCallForResponse
(
iq
,
self
.
_on_bob_received
,
{
'
cid
'
:
cid
})
{
'
cid
'
:
cid
})
# process and dispatch a groupchat message
def
dispatch_gc_message
(
self
,
msg
,
frm
,
msgtxt
,
jid
,
tim
):
has_timestamp
=
bool
(
msg
.
timestamp
)
statusCode
=
msg
.
getStatusCode
()
displaymarking
=
None
seclabel
=
msg
.
getTag
(
'
securitylabel
'
)
if
seclabel
and
seclabel
.
getNamespace
()
==
common
.
xmpp
.
NS_SECLABEL
:
# Ignore message from room in which we are not
displaymarking
=
seclabel
.
getTag
(
'
displaymarking
'
)
if
jid
not
in
self
.
last_history_time
:
return
captcha
=
msg
.
getTag
(
'
captcha
'
,
namespace
=
common
.
xmpp
.
NS_CAPTCHA
)
if
captcha
:
captcha
=
captcha
.
getTag
(
'
x
'
,
namespace
=
common
.
xmpp
.
NS_DATA
)
found
=
helpers
.
replace_dataform_media
(
captcha
,
msg
)
if
not
found
:
self
.
get_bob_data
(
uri_data
,
frm
,
self
.
dispatch_gc_message
,
[
msg
,
frm
,
msgtxt
,
jid
,
tim
],
0
)
return
self
.
dispatch
(
'
GC_MSG
'
,
(
frm
,
msgtxt
,
tim
,
has_timestamp
,
msg
.
getXHTML
(),
statusCode
,
displaymarking
,
captcha
))
tim_int
=
int
(
float
(
mktime
(
tim
)))
if
gajim
.
config
.
should_log
(
self
.
name
,
jid
)
and
not
\
tim_int
<=
self
.
last_history_time
[
jid
]
and
msgtxt
and
frm
.
find
(
'
/
'
)
>=
0
:
# if frm.find('/') < 0, it means message comes from room itself
# usually it hold description and can be send at each connection
# so don't store it in logs
try
:
gajim
.
logger
.
write
(
'
gc_msg
'
,
frm
,
msgtxt
,
tim
=
tim
)
# store in memory time of last message logged.
# this will also be saved in rooms_last_message_time table
# when we quit this muc
self
.
last_history_time
[
jid
]
=
mktime
(
tim
)
except
exceptions
.
PysqliteOperationalError
,
e
:
self
.
dispatch
(
'
DB_ERROR
'
,
(
_
(
'
Disk Write Error
'
),
str
(
e
)))
except
exceptions
.
DatabaseMalformed
:
pritext
=
_
(
'
Database Error
'
)
sectext
=
_
(
'
The database file (%s) cannot be read. Try to
'
'
repair it (see http://trac.gajim.org/wiki/DatabaseBackup)
'
'
or remove it (all history will be lost).
'
)
%
\
common
.
logger
.
LOG_DB_PATH
self
.
dispatch
(
'
DB_ERROR
'
,
(
pritext
,
sectext
))
def
_presenceCB
(
self
,
con
,
prs
):
def
_presenceCB
(
self
,
con
,
prs
):
"""
"""
Called when we receive a presence
Called when we receive a presence
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment