Fixed bug introduced in commit 3cb16af5e323ada152cbac0a2a55cd4607bf6e7b
(cherry picked from commit f5cca67deb42750beac89daa05ba1558d4ec278e)