Skip to content

Commit f89c89d

Browse files
MarijnGroenalexdrans
authored andcommitted
fixed the llocationi of the extra description
1 parent 63d3370 commit f89c89d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

lib/OpenCatalog/product.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ icecat.prototype.getReleaseDate = function() {
8484
*/
8585
icecat.prototype.getLongDescription = function() {
8686
try {
87-
if(!this.productData.ProductDescription[0].$.LongDesc){
88-
return this.productData.SummaryDescription[0].$.LongSummaryDescitpion
87+
if(typeof this.productData.ProductDescription[0].$ === 'undefined'){
88+
return this.productData.SummaryDescription[0].LongSummaryDescription[0]._
8989
}
9090
return this.productData.ProductDescription[0].$.LongDesc
9191
} catch (e) {
@@ -99,8 +99,8 @@ icecat.prototype.getLongDescription = function() {
9999
*/
100100
icecat.prototype.getShortDescription = function() {
101101
try {
102-
if(!this.productData.ProductDescription[0].$.ShortDesc){
103-
return this.productData.SummaryDescription[0].$.ShortSummaryDescitpion
102+
if(typeof this.productData.ProductDescription[0].$ === 'undefined'){
103+
return this.productData.SummaryDescription[0].ShortSummaryDescitpion[0]._
104104
}
105105
return this.productData.ProductDescription[0].$.ShortDesc;
106106
} catch (e) {
@@ -268,4 +268,4 @@ icecat.prototype.getCategoryFeatureGroups = function() {
268268
}
269269
};
270270

271-
module.exports = icecat;
271+
module.exports = icecat;

0 commit comments

Comments
 (0)