Why does my code call this interface indefinitely? it's a dead loop.

 getSmscode() {
        var reg = /^1[3|4|5|7|8][0-9]\d{8}$/
        if (this.registerInfo.phone == "") {
            this.$message({
                message: "",
                type: "warning"
            });
        } else if (!reg.test(this.registerInfo.phone)) {
            this.$message({
                message: "",
                type: "warning"
            });
        } else {
            this.fromdataSmscode.append("phone", this.registerInfo.phone);
            this.$axios.post(url.sendSMS, this.fromdataSmscode).then(response => {
                    console.log(response);
                    this.$message({
                        message: "",
                        type: "success"
                    })
                    this.getCode()
                    
                })
                .catch(response => {
                    console.log(response);
                    this.$message(response.data.errorMessage);
                })
        }
    }
Sep.03,2021

                    return  this.$message({                   
                        message: "",
                        type: "warning"
                     });
Menu