Backport PR
#2261: Fix: longest_substr([]) -> ''...
Backport PR
#2261: Fix: longest_substr([]) -> ''
Previously the algorithm used to find the longest common starting substring
unintentionally raised an error when it was called on an empty list.
This should fix the issue of an error being raised when running %paste
on an empty clipboard (#2252).