[totem] opensubtitles: Fix a function signature



commit 73a637145a4691e91d268c4ba00ce624be989544
Author: Mathieu Bridon <bochecha daitauha fr>
Date:   Wed Jun 27 15:45:14 2018 +0200

    opensubtitles: Fix a function signature
    
    Commit 6afabc102b4ac50cbf4497847fceeaae1dfa07f5 changed the method
    signature to please pylint:
    
    -    def _show_dialog (self, params, _):
    +    def _show_dialog (self, _):
    
    This effectively makes the method take a single parameter instead of
    two.
    
    However the method is typically called with two arguments. (it is an
    action callback)
    
    This completely broke the OpenSubtitles plugin, which wasn't able to
    show its dialog any more.
    
    This commit makes the code ignore all parameters of the method, so
    Pylint is still happy, but fixes the issue.

 src/plugins/opensubtitles/opensubtitles.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/plugins/opensubtitles/opensubtitles.py b/src/plugins/opensubtitles/opensubtitles.py
index d11e2816..80fc810a 100644
--- a/src/plugins/opensubtitles/opensubtitles.py
+++ b/src/plugins/opensubtitles/opensubtitles.py
@@ -514,7 +514,7 @@ class OpenSubtitles (GObject.Object, # pylint: disable=R0902
         self._tree_view.connect ('row-activated',
                                self.__on_treeview__row_activate)
 
-    def _show_dialog (self, _):
+    def _show_dialog (self, *_):
         if not self._dialog:
             self._build_dialog ()
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]