8000 Replace the _backend_mod attribute access with the call to _get_backe… · matplotlib/matplotlib@30da817 · GitHub
[go: up one dir, main page]

Skip to content

Commit 30da817

Browse files
committed
Replace the _backend_mod attribute access with the call to _get_backend_mod function in Figure.__setstate__
1 parent 8afcbc2 commit 30da817

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/matplotlib/figure.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3038,7 +3038,8 @@ def __setstate__(self, state):
30383038
import matplotlib._pylab_helpers as pylab_helpers
30393039
allnums = plt.get_fignums()
30403040
num = max(allnums) + 1 if allnums else 1
3041-
mgr = plt._backend_mod.new_figure_manager_given_figure(num, self)
3041+
backend = plt._get_backend_mod()
3042+
mgr = backend.new_figure_manager_given_figure(num, self)
30423043
pylab_helpers.Gcf._set_new_active_manager(mgr)
30433044
plt.draw_if_interactive()
30443045

0 commit comments

Comments
 (0)
0