[BZ-1078235] add check for null configuration in legacy api
(cherry picked from commit 149e5b6e5c25c098459bc8407d4244a9c006f470)