[libvirt] [PATCH 17/22] apibuild: Simplify strip_lead_star()

Daniel P. Berrangé berrange at redhat.com
Mon Mar 19 10:59:53 UTC 2018


On Sat, Mar 17, 2018 at 02:23:35PM +0000, Radostin Stoyanov wrote:
> The method strip_lead_star() removes a single leading asterisk
> character from a string by ignoring leading whitespace, otherwise it
> returns the original string.
> 
> This could be achieved with a single if-statement followed by replace.
> 
> Signed-off-by: Radostin Stoyanov <rstoyanov1 at gmail.com>
> ---
>  docs/apibuild.py | 11 ++---------
>  1 file changed, 2 insertions(+), 9 deletions(-)

Reviewed-by: Daniel P. Berrangé <berrange at redhat.com>


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|




More information about the libvir-list mailing list