Fixed use of deprecated methods where Capabilities should be used instead.