Add another conditional check in case bundle is undefined