diff --git a/curriculum/challenges/english/14-responsive-web-design-22/learn-html-by-building-a-cat-photo-app/5efae0543cbd2bbdab94e333.md b/curriculum/challenges/english/14-responsive-web-design-22/learn-html-by-building-a-cat-photo-app/5efae0543cbd2bbdab94e333.md index 67e7fe3252b..2d1d48e0681 100644 --- a/curriculum/challenges/english/14-responsive-web-design-22/learn-html-by-building-a-cat-photo-app/5efae0543cbd2bbdab94e333.md +++ b/curriculum/challenges/english/14-responsive-web-design-22/learn-html-by-building-a-cat-photo-app/5efae0543cbd2bbdab94e333.md @@ -35,9 +35,15 @@ The Cats `img` element should be nested in the `figure` element. ```js const catsImg = document.querySelectorAll('figure > img')[1]; -assert( - catsImg && - catsImg.getAttribute('src').toLowerCase() === 'https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg' +assert.exists(catsImg); +``` + +The third image should have a `src` attribute set to `https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg`. + +```js +const catsImg = document.querySelectorAll('figure > img')[1]; +assert.strictEqual( + catsImg?.src?.toLowerCase(), 'https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg' ); ``` diff --git a/curriculum/challenges/english/25-front-end-development/workshop-cat-photo-app/5efae0543cbd2bbdab94e333.md b/curriculum/challenges/english/25-front-end-development/workshop-cat-photo-app/5efae0543cbd2bbdab94e333.md index 3147f20960c..fc47c5fce88 100644 --- a/curriculum/challenges/english/25-front-end-development/workshop-cat-photo-app/5efae0543cbd2bbdab94e333.md +++ b/curriculum/challenges/english/25-front-end-development/workshop-cat-photo-app/5efae0543cbd2bbdab94e333.md @@ -35,8 +35,15 @@ The Cats `img` element should be nested in the `figure` element. ```js const catsImg = document.querySelectorAll('figure > img')[1]; -assert.equal( - catsImg?.getAttribute('src')?.toLowerCase(), 'https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg' +assert.exists(catsImg); +``` + +The third image should have a `src` attribute set to `https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg`. + +```js +const catsImg = document.querySelectorAll('figure > img')[1]; +assert.strictEqual( + catsImg?.src?.toLowerCase(), 'https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg' ); ```