materials available bug fix