Comparing two approaches to the K-theory classification of D-branes