Fix for #2419: There is no function maxDescription in Oauth_application class (broke the 'description too long' error message when editing oauth app registrations)
This commit is contained in:
		@@ -188,7 +188,7 @@ class EditApplicationAction extends OwnerDesignAction
 | 
				
			|||||||
        } elseif (Oauth_application::descriptionTooLong($description)) {
 | 
					        } elseif (Oauth_application::descriptionTooLong($description)) {
 | 
				
			||||||
            $this->showForm(sprintf(
 | 
					            $this->showForm(sprintf(
 | 
				
			||||||
                _('Description is too long (max %d chars).'),
 | 
					                _('Description is too long (max %d chars).'),
 | 
				
			||||||
                                    Oauth_application::maxDescription()));
 | 
					                                    Oauth_application::maxDesc()));
 | 
				
			||||||
            return;
 | 
					            return;
 | 
				
			||||||
        } elseif (mb_strlen($source_url) > 255) {
 | 
					        } elseif (mb_strlen($source_url) > 255) {
 | 
				
			||||||
            $this->showForm(_('Source URL is too long.'));
 | 
					            $this->showForm(_('Source URL is too long.'));
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -170,7 +170,7 @@ class NewApplicationAction extends OwnerDesignAction
 | 
				
			|||||||
        } elseif (Oauth_application::descriptionTooLong($description)) {
 | 
					        } elseif (Oauth_application::descriptionTooLong($description)) {
 | 
				
			||||||
            $this->showForm(sprintf(
 | 
					            $this->showForm(sprintf(
 | 
				
			||||||
                _('Description is too long (max %d chars).'),
 | 
					                _('Description is too long (max %d chars).'),
 | 
				
			||||||
                Oauth_application::maxDescription()));
 | 
					                Oauth_application::maxDesc()));
 | 
				
			||||||
            return;
 | 
					            return;
 | 
				
			||||||
        } elseif (empty($source_url)) {
 | 
					        } elseif (empty($source_url)) {
 | 
				
			||||||
            $this->showForm(_('Source URL is required.'));
 | 
					            $this->showForm(_('Source URL is required.'));
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user