Skip to content

Commit b635000

Browse files
committed
no need to floor distance, it is done before now
1 parent 7e9c9f5 commit b635000

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

frontend/src/components/app/recommendations/RecommendationCard.vue

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,21 +23,21 @@
2323
<h1 class="text-4xl font-bold leading-none">{{this.recommendation.first_name}}</h1>
2424
<h1 class="text-2xl ml-2 leading-none mb-1">{{this.recommendation.age}}</h1>
2525
</div>
26-
<h1 class="text-lg">{{getDistance()}}km away</h1>
26+
<h1 class="text-lg">{{this.recommendation.distance}}km away</h1>
2727
</div>
2828
</div>
2929
</template>
3030

3131
<script>
3232
/* eslint-disable no-else-return */
33+
/* eslint-disable max-len */
3334
3435
export default {
35-
props: ['recommendation', 'index'],
36+
props: ['recommendation'],
3637
methods: {
3738
getPrimaryImage() {
3839
const userImages = this.recommendation.images;
3940
let imageForShowcase;
40-
// console.log(this.recommendation);
4141
for (let i = 0; i < userImages.length; i += 1) {
4242
if (userImages[i].is_primary) {
4343
imageForShowcase = userImages[i].link;
@@ -63,9 +63,6 @@ export default {
6363
}
6464
return '../../../assets/recommendations/avatars/other.png';
6565
},
66-
getDistance() {
67-
return Math.floor(this.recommendation.distance);
68-
},
6966
},
7067
};
7168
</script>

0 commit comments

Comments
 (0)