Fixed a bug with missing extension