Skip to content

Commit 6e06af4

Browse files
Disabled submission URL tests
1 parent 8aaaca7 commit 6e06af4

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

api/challenge.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ module.exports = ({
3333
title.length > 50 ? 'Title must not be longer than 32 characters'
3434
: title.length <= 2 ? 'Title must be longer than 2 characters'
3535
: url.length > 500 ? 'URL must not be longer than 500 characters'
36-
: !/^https:\/\/(github\.com\/[^\/ ]+\/[^\/ ]+|codepen\.io\/[^\/ ]+\/pen\/[^\/ ]+|jsfiddle\.net\/[^\/ ]+)\S*/.test(url) ? 'Invalid URL'
3736
: ''
3837

3938
if (error) return res.json({

pages/submit.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
v-model="inputs.url"
1818
/>
1919
<p class="error" v-show="errors.url.length > 0">{{errors.url}}</p>
20-
<p :class="`${!user.id ? 'disabled' : ''}`">
20+
<!-- <p :class="`${!user.id ? 'disabled' : ''}`">
2121
*Must be a <a
2222
href="https://github.com/"
2323
target="_blank"
@@ -28,7 +28,7 @@
2828
href="https://jsfiddle.net/"
2929
target="_blank"
3030
>JSFiddle</a> link.
31-
</p>
31+
</p> -->
3232
<!-- <textarea
3333
placeholder="Brief description of your project, not required"
3434
@blur="e => errorCheck('description')"
@@ -183,7 +183,6 @@
183183
case 'url':
184184
this.errors.url =
185185
url.length > 500 ? 'URL must not be longer than 500 characters'
186-
: !/^https:\/\/(github\.com\/[^\/ ]+\/[^\/ ]+|codepen\.io\/[^\/ ]+\/pen\/[^\/ ]+|jsfiddle\.net\/[^\/ ]+)\S*/.test(url) ? 'Invalid URL'
187186
: ''
188187
break
189188
// case 'description':

0 commit comments

Comments
 (0)